]> git.donarmstrong.com Git - mothur.git/blobdiff - unifracunweightedcommand.cpp
fixed unifrac bug with multiple processors if numComps was less than processors....
[mothur.git] / unifracunweightedcommand.cpp
index ccd5aa4995392ab9f306fa986f6fc8169e08903a..566fd10c8ef9ff90849896982343e6970bdeaba5 100644 (file)
@@ -198,6 +198,8 @@ int UnifracUnweightedCommand::execute() {
                randomData.resize(numComp,0); //data[0] = unweightedscore
                //create new tree with same num nodes and leaves as users
                
+               if (numComp < processors) { processors = numComp;  }
+               
                outSum << "Tree#" << '\t' << "Groups" << '\t'  <<  "UWScore" <<'\t' << "UWSig" <<  endl;
                m->mothurOut("Tree#\tGroups\tUWScore\tUWSig"); m->mothurOutEndLine();
                
@@ -259,7 +261,7 @@ int UnifracUnweightedCommand::execute() {
                                }
                                
                                //report progress
-                               m->mothurOut("Iter: " + toString(j+1)); m->mothurOutEndLine();  
+//                             m->mothurOut("Iter: " + toString(j+1)); m->mothurOutEndLine();  
                        }
        
                        for(int a = 0; a < numComp; a++) {