]> git.donarmstrong.com Git - mothur.git/blobdiff - collect.cpp
fixed bug with displaying info for collect.shared() and summary.shared().
[mothur.git] / collect.cpp
index a06c320f37f952c527533abae162e13af5a438b1..2ed5ca7f10eeefdb860ae9fc7b5859b5eb239c0e 100644 (file)
@@ -70,6 +70,7 @@ try {
                        SharedRAbundVector* temp = new SharedRAbundVector(sharedorder->getNumBins());
                        temp->setLabel(sharedorder->getLabel());
                        temp->setGroup(globaldata->gGroupmap->namesOfGroups[i]);
+                       temp->setGroupIndex(globaldata->gGroupmap->groupIndex[globaldata->gGroupmap->namesOfGroups[i]]);
                        lookup.push_back(temp);
                }
 
@@ -111,7 +112,7 @@ try {
                                int n = 1;
                                for (int k = 0; k < (lookup.size() - 1); k++) { // pass cdd each set of groups to commpare
                                        for (int l = n; l < lookup.size(); l++) {
-                                               ccd->updateSharedData(lookup[k], lookup[l], i+1, numGroupComb);
+                                               ccd->updateSharedData(lookup[k], lookup[l], i+1, globaldata->gGroupmap->namesOfGroups.size());
                                        }
                                        n++;
                                }
@@ -125,7 +126,7 @@ try {
                        int n = 1;
                        for (int k = 0; k < (lookup.size() - 1); k++) { // pass cdd each set of groups to commpare
                                for (int l = n; l < lookup.size(); l++) {
-                                       ccd->updateSharedData(lookup[k], lookup[l], totalNumSeq, numGroupComb);
+                                       ccd->updateSharedData(lookup[k], lookup[l], totalNumSeq, globaldata->gGroupmap->namesOfGroups.size());
                                }
                                n++;
                        }