]> git.donarmstrong.com Git - mothur.git/blobdiff - pipelinepdscommand.cpp
added pairwise.seqs
[mothur.git] / pipelinepdscommand.cpp
index 26969d81c7b6d95a0f7c603489be1da984ea7d99..22f5a97b498187b23b651695e8b3d9a1b8cef1f6 100644 (file)
@@ -238,6 +238,8 @@ int PipelineCommand::execute(){
        try {
                if (abort == true) { return 0; }
                
+               int start = time(NULL);
+               
                if (pipeFilename == "") { 
                        createPatsPipeline(); 
                        
@@ -279,6 +281,8 @@ int PipelineCommand::execute(){
                
                if (m->control_pressed) { return 0; }
                
+               m->mothurOut("It took " + toString(time(NULL) - start) + " secs to run the pipeline analysis."); m->mothurOutEndLine(); m->mothurOutEndLine();
+               
                m->mothurOutEndLine();
                m->mothurOut("Output File Names: "); m->mothurOutEndLine();
                for (int i = 0; i < outputNames.size(); i++) {  m->mothurOut(outputNames[i]); m->mothurOutEndLine();    }
@@ -595,33 +599,33 @@ void PipelineCommand::createPatsPipeline(){
                //trim.seqs command
                string fastaFile = m->getRootName(m->getSimpleName(sffFile)) + "fasta";
                string qualFile = m->getRootName(m->getSimpleName(sffFile)) + "qual";
-               //thisCommand = "trim.seqs(processors=" + toString(processors) + ", fasta=" + fastaFile + ", allfiles=F, maxambig=0, maxhomop=8, flip=T, bdiffs=1, pdiffs=2, qwindowaverage=35, qwindowsize=50, oligos=" + oligosFile + ", qfile=" + qualFile + ")";
+               //thisCommand = "trim.seqs(processors=" + toString(processors) + ", fasta=" + fastaFile + ", allfiles=T, maxambig=0, maxhomop=8, flip=T, bdiffs=1, pdiffs=2, qwindowaverage=35, qwindowsize=50, oligos=" + oligosFile + ", qfile=" + qualFile + ")";
                //commands.push_back(thisCommand);
                
                //unique.seqs
                string groupFile = m->getRootName(m->getSimpleName(fastaFile)) + "groups";
                qualFile =  m->getRootName(m->getSimpleName(fastaFile)) + "trim.qual";
                fastaFile =  m->getRootName(m->getSimpleName(fastaFile)) + "trim.fasta";
-               //thisCommand = "unique.seqs(fasta=" + fastaFile + ")"; 
-               //commands.push_back(thisCommand);
+               thisCommand = "unique.seqs(fasta=" + fastaFile + ")"; 
+               commands.push_back(thisCommand);
                
                //align.seqs
                string nameFile = m->getRootName(m->getSimpleName(fastaFile)) + "names";
                fastaFile = m->getRootName(m->getSimpleName(fastaFile)) + "unique" + m->getExtension(fastaFile);
-               //thisCommand = "align.seqs(processors=" + toString(processors) + ", candidate=" + fastaFile + ", template=" + alignFile + ")";
-               //commands.push_back(thisCommand);
+               thisCommand = "align.seqs(processors=" + toString(processors) + ", candidate=" + fastaFile + ", template=" + alignFile + ")";
+               commands.push_back(thisCommand);
                
                //screen.seqs
                fastaFile = m->getRootName(m->getSimpleName(fastaFile)) + "align";
-               //thisCommand = "screen.seqs(processors=" + toString(processors) + ", fasta=" + fastaFile + ", name=" + nameFile + ", group=" + groupFile + ", optimize=end-minlength)";
-       //      commands.push_back(thisCommand);
+               thisCommand = "screen.seqs(processors=" + toString(processors) + ", fasta=" + fastaFile + ", name=" + nameFile + ", group=" + groupFile + ", optimize=end-minlength)";
+               commands.push_back(thisCommand);
                
                //chimera.slayer
                fastaFile = m->getRootName(m->getSimpleName(fastaFile)) + "good" + m->getExtension(fastaFile);
                nameFile = m->getRootName(m->getSimpleName(nameFile)) + "good" + m->getExtension(nameFile);
                groupFile = m->getRootName(m->getSimpleName(groupFile)) + "good" + m->getExtension(groupFile);
-               //thisCommand = "chimera.slayer(processors=" + toString(processors) + ", fasta=" + fastaFile + ", template=" + chimeraFile + ")";
-       //      commands.push_back(thisCommand);
+               thisCommand = "chimera.slayer(processors=" + toString(processors) + ", fasta=" + fastaFile + ", template=" + chimeraFile + ")";
+               commands.push_back(thisCommand);
                
                //remove.seqs
                string accnosFile = m->getRootName(m->getSimpleName(fastaFile))  + "slayer.accnos";