diff --git a/w2v-server.pl b/w2v-server.pl
index e177932..e7ad7f5 100644
--- a/w2v-server.pl
+++ b/w2v-server.pl
@@ -34,6 +34,7 @@
   my $perplexity=$c->param('perplexity') || 20;
   my $epsilon=$c->param('epsilon') || 5;
   my $som=$c->param('som') || 0;
+  my $sort=$c->param('sort') || 0;
   my $res;
 	my @lists;
 	my @collocations;
@@ -43,15 +44,15 @@
     for my $w (split(' *\| *', $word)) {
 			$c->app->log->debug('Looking for neighbours of '.$w);
       if($opt_i) {
-        $res = get_neighbours(encode("iso-8859-1", $w), $no_nbs);
+        $res = get_neighbours(encode("iso-8859-1", $w), $no_nbs, $sort);
       } else {
-        $res = get_neighbours($w, $no_nbs);
+        $res = get_neighbours($w, $no_nbs, $sort);
       }
       push(@lists, $res->{paradigmatic});
 		}
 	}
 	$word =~ s/ *\| */ | /g;
-  $c->render(template=>"index", word=>$word, no_nbs=>$no_nbs, no_iterations => $no_iterations, epsilon=> $epsilon, perplexity=> $perplexity, show_som=>$som, lists=> \@lists, collocators=> $res->{syntagmatic});
+  $c->render(template=>"index", word=>$word, no_nbs=>$no_nbs, no_iterations => $no_iterations, epsilon=> $epsilon, perplexity=> $perplexity, show_som=>$som, sort=>$sort, lists=> \@lists, collocators=> $res->{syntagmatic});
 };
 
 $daemon->run; # app->start;
@@ -264,7 +265,7 @@
 
         target_sums[target] += f;
         if(f > worstbest) {
-          for (b = 0; b < N/2; b++) {
+          for (b = 0; b < N; b++) {
             if (f > bestf[b]) {
 							memmove(bestf + b + 1, bestf + b, (N - b -1) * sizeof(float));
 							memmove(besti + b + 1, besti + b, (N - b -1) * sizeof(long long));
@@ -275,8 +276,8 @@
 							break;
             }
           }
-          if(b == N/2 - 1)
-            worstbest = bestf[N/2-1];
+          if(b == N - 1)
+            worstbest = bestf[N-1];
         }
       }
       printf("%d %.2f\n", max_target, max_f);
@@ -413,7 +414,7 @@
 }
 
 
-SV *get_neighbours(char *st1, int N) {
+SV *get_neighbours(char *st1, int N, int sort_by) {
   HV *result = newHV();
 	float *target_sums, bestd[MAX_NEIGHBOURS], bestn[MAX_NEIGHBOURS], bests[MAX_NEIGHBOURS], vec[max_size];
 	long besti[MAX_NEIGHBOURS], bestp[MAX_NEIGHBOURS], a, b, c, d, slice;
@@ -506,6 +507,7 @@
     bestd[b] = 0;
     bestn[b] = 0;
     bestp[b] = 0;
+    bests[b] = 0;
   }
 
   printf("Waiting for syn threads to join\n");
@@ -520,24 +522,48 @@
     bestd[b] = syn_nbs[0]->dist[b];
     bestn[b] = syn_nbs[0]->norm[b];
     bestp[b] = syn_nbs[0]->pos[b];
+    bests[b] = target_sums[syn_nbs[0]->index[b]];
   }
   
-  
-  for(a=1; a < syn_threads; a++) {
-    for(b=0; b < syn_nbs[a]->length; b++) {
-      for(c=0; c < MAX_NEIGHBOURS; c++) {
-        if(syn_nbs[a]->dist[b] > bestd[c]) {
-          for(d=N-1; d>c; d--) {
-            bestd[d] = bestd[d-1];
-            besti[d] = besti[d-1];
-            bestn[d] = bestn[d-1];
-            bestp[d] = bestp[d-1];
+  if(sort_by != 1) { // sort by responsiveness
+    for(a=1; a < syn_threads; a++) {
+      for(b=0; b < syn_nbs[a]->length; b++) {
+        for(c=0; c < MAX_NEIGHBOURS; c++) {
+          if(syn_nbs[a]->dist[b] > bestd[c]) {
+            for(d=MAX_NEIGHBOURS-1; d>c; d--) {
+              bestd[d] = bestd[d-1];
+              besti[d] = besti[d-1];
+              bestn[d] = bestn[d-1];
+              bestp[d] = bestp[d-1];
+            }
+            besti[c] = syn_nbs[a]->index[b];
+            bestd[c] = syn_nbs[a]->dist[b];
+            bestn[c] = syn_nbs[a]->norm[b];
+            bestp[c] = syn_nbs[a]->pos[b];
+            break;
           }
-          besti[c] = syn_nbs[a]->index[b];
-          bestd[c] = syn_nbs[a]->dist[b];
-          bestn[c] = syn_nbs[a]->norm[b];
-          bestp[c] = syn_nbs[a]->pos[b];
-          break;
+        }
+      }
+    }
+  } else { // sort by mean p
+    for(a=1; a < syn_threads; a++) {
+      for(b=0; b < syn_nbs[a]->length; b++) {
+        for(c=0; c < MAX_NEIGHBOURS; c++) {
+          if(target_sums[syn_nbs[a]->index[b]] > bests[c]) {
+            for(d=MAX_NEIGHBOURS-1; d>c; d--) {
+              bestd[d] = bestd[d-1];
+              besti[d] = besti[d-1];
+              bestn[d] = bestn[d-1];
+              bestp[d] = bestp[d-1];
+              bests[d] = bests[d-1];
+            }
+            besti[c] = syn_nbs[a]->index[b];
+            bestd[c] = syn_nbs[a]->dist[b];
+            bestn[c] = syn_nbs[a]->norm[b];
+            bestp[c] = syn_nbs[a]->pos[b];
+            bests[c] = target_sums[syn_nbs[a]->index[b]];
+            break;
+          }
         }
       }
     }
@@ -835,6 +861,11 @@
 		max. neighbours: <input type="text" size="8" name="n" value="<%= $no_nbs %>">
 		max. iterations: <input type="text" name="N" size="8" value="<%= $no_iterations %>">
     SOM <input type="checkbox" name="som" value="1" <%= ($show_som ? "checked" : "") %>>
+    <span>  </span>sort collocators by
+    <select name="sort">
+      <option value="0"  <%= ($sort!=1? "selected":"") %>>responsiveness</option>
+      <option value="1" <%= ($sort==1? "selected":"") %>>mean p</option>
+    </select>
 		<span>  </span><input type="submit" value="Show">
 	</form>
 	<br>
