X-Git-Url: https://git.donarmstrong.com/?a=blobdiff_plain;f=slibshuff.cpp;h=92998e66ac1eadb442b5b0afc0cfee33835f902a;hb=372fb21ea66ced432b109225851a1b80ef0491a3;hp=a9710ded9303b2f93373216bf2d22ba3c81c527c;hpb=197c6d3303439582502840980d6a85cf3aab2314;p=mothur.git diff --git a/slibshuff.cpp b/slibshuff.cpp index a9710de..92998e6 100644 --- a/slibshuff.cpp +++ b/slibshuff.cpp @@ -24,7 +24,6 @@ float SLibshuff::evaluatePair(int i, int j){ vector > SLibshuff::evaluateAll(){ try{ savedMins.resize(numGroups); - vector > dCXYValues(numGroups); for(int i=0;i > SLibshuff::evaluateAll(){ return dCXYValues; } catch(exception& e) { - cout << "Standard Error: " << e.what() << " has occurred in the SLibshuff class Function evaluateAll. Please contact Pat Schloss at pschloss@microbio.umass.edu." << "\n"; + m->errorOut(e, "SLibshuff", "evaluateAll"); exit(1); } - catch(...) { - cout << "An unknown error has occurred in the SLibshuff class function evaluateAll. Please contact Pat Schloss at pschloss@microbio.umass.edu." << "\n"; - exit(1); - } - } /***********************************************************************/ double SLibshuff::sCalculate(int x, int y){ try{ + double sum = 0.0,t=0.0; + minX = getMinX(x); + + if (m->control_pressed) { return sum; } + minXY = getMinXY(x,y); + + if (m->control_pressed) { return sum; } sort(minX.begin(), minX.end()); + + if (m->control_pressed) { return sum; } + sort(minXY.begin(), minXY.end()); + + if (m->control_pressed) { return sum; } - double sum = 0.0,t=0.0; int ix=0,iy=0; while( (ix < groupSizes[x]) && (iy < groupSizes[x]) ) { double h = (ix-iy)/double(groupSizes[x]); @@ -103,14 +108,9 @@ double SLibshuff::sCalculate(int x, int y){ return sum; } catch(exception& e) { - cout << "Standard Error: " << e.what() << " has occurred in the SLibshuff class Function sCalculate. Please contact Pat Schloss at pschloss@microbio.umass.edu." << "\n"; + m->errorOut(e, "SLibshuff", "sCalculate"); exit(1); } - catch(...) { - cout << "An unknown error has occurred in the SLibshuff class function sCalculate. Please contact Pat Schloss at pschloss@microbio.umass.edu." << "\n"; - exit(1); - } - } /***********************************************************************/