- //sorts putting largest matches first
- sort(seqMatches.begin(), seqMatches.end(), compareSeqMatches);
+ if (num != 1) {
+ vector<seqMatch> seqMatches; seqMatches.resize(numSeqs);
+ for(int i=0;i<numSeqs;i++){
+ seqMatches[i].seq = i;
+ seqMatches[i].match = matches[i];
+ }
+
+ //sorts putting largest matches first
+ sort(seqMatches.begin(), seqMatches.end(), compareSeqMatches);
+
+ searchScore = seqMatches[0].match;
+ searchScore = 100 * searchScore / (float) numKmers; // return the Sequence object corresponding to the db