Another DBC-plot (subrec ranks in DBC's order)
authorHeikki Levanto <heikki@indexdata.dk>
Wed, 4 Dec 2013 15:30:59 +0000 (16:30 +0100)
committerHeikki Levanto <heikki@indexdata.dk>
Wed, 4 Dec 2013 15:30:59 +0000 (16:30 +0100)
heikki/dbc-os/test2.sh
src/relevance.c

index 3765954..86532e7 100755 (executable)
@@ -136,14 +136,15 @@ echo "
   set term png
   set out \"cluster.png\"
   set title \"$Q\"
-  set yrange [0:20000]
+  #set yrange [0:5000]
   plot \"merge.data\" using 1:3 with points title \"records\", \
-       \"merge.data\" using 1:4 with points title \"merged score\", \
-       \"merge.data\" using 1:5 with points title \"sum score\", \
        \"merge.data\" using 1:6 with points title \"avg score\"
 " > plot.cmd
 cat plot.cmd | gnuplot
 
+       #\"merge.data\" using 1:4 with points title \"merged score\", \
+       #\"merge.data\" using 1:5 with points title \"sum score\", \
+
 echo
 
 echo "All done"
index bd7a082..1f3eb28 100644 (file)
@@ -593,6 +593,10 @@ void relevance_prepare_read(struct relevance *rel, struct reclist *reclist,
                 else
                 { // only one record, take the easy way out of merging (and don't bother plotting)
                     mergescore = atof( score ) * 10000;
+                    wrbuf_printf(w,"mergeplot %d  x %d %f %f %d\n", clusternumber, mergescore,
+                        1.0*mergescore, 1.0*mergescore, nclust );
+                    yaz_log(YLOG_LOG,"mergeplot %d  x %d %f %f %d", clusternumber, mergescore,
+                        1.0*mergescore, 1.0*mergescore, nclust );
                 }
             } // merge score
             id = getfield(bestrecord, "id");
@@ -608,7 +612,7 @@ void relevance_prepare_read(struct relevance *rel, struct reclist *reclist,
             wrbuf_printf(w,"plotline: %d %d %d %d %d %d %d # %s %s\n",
                             norm->num, bestrecord->position,
                             tfrel, robinscore, solrscore, normscore, mergescore, idbuf, title );
-            relevance = mergescore;
+            relevance = normscore;
         }
         rec->relevance_score = relevance;
     }