]> git.donarmstrong.com Git - mothur.git/blob - globaldata.cpp
added get.repseqs command, started matrix output command
[mothur.git] / globaldata.cpp
1 #include "globaldata.hpp"
2 #include "tree.h"
3 #include "sparsematrix.hpp"
4
5 /*******************************************************/
6
7 /******************************************************/
8 GlobalData* GlobalData::getInstance() {
9         if( _uniqueInstance == 0 ) {
10                 _uniqueInstance = new GlobalData();
11         }
12         return _uniqueInstance;
13 }
14 /*******************************************************/
15
16 /******************************************************/
17 //This function parses through the option string of the command to remove its parameters
18 void GlobalData::parseGlobalData(string commandString, string optionText){
19         try {
20                 commandName = commandString; //save command name to be used by other classes
21                 
22                 //set all non filename paramters to default
23                 reset();
24                 
25                 //clears out data from previous read
26                 if ((commandName == "read.dist") || (commandName == "read.otu") || (commandName == "read.tree")) { 
27                         clear();
28                         gGroupmap = NULL;
29                         gTree.clear();
30                         Treenames.clear();
31                         labels.clear(); lines.clear(); groups.clear();
32                         allLines = 1;
33                 }
34                 
35                 //saves help request
36                 if (commandName =="help") {
37                         helpRequest = optionText;
38                 }
39                 
40                 if (commandName == "libshuff") {
41                         iters = "10000";
42                         cutoff = "1.0";
43                 }
44                 
45                 //set default value for cutoff
46                 if (commandName == "dist.seqs") {       cutoff = "1.0";         }
47
48                 string key, value;              
49                 //reads in parameters and values
50                 if((optionText != "") && (commandName != "help")){
51                         while((optionText.find_first_of(',') != -1)) {  //while there are parameters
52                                 splitAtComma(value, optionText);
53                                 splitAtEquals(key, value);
54                                 
55                                 if (key == "phylip" )   { phylipfile = value; inputFileName = value; fileroot = value; format = "phylip";       }
56                                 if (key == "column" )   { columnfile = value; inputFileName = value; fileroot = value; format = "column";       }
57                                 if (key == "list" )             { listfile = value; inputFileName = value; fileroot = value; format = "list";           }
58                                 if (key == "rabund" )   { rabundfile = value; inputFileName = value; fileroot = value; format = "rabund";       }
59                                 if (key == "sabund" )   { sabundfile = value; inputFileName = value; fileroot = value; format = "sabund";       } 
60                                 if (key == "fasta" )    { fastafile = value; inputFileName = value; fileroot = value; format = "fasta";         }
61                                 if (key == "nexus" )    { nexusfile = value; inputFileName = value; fileroot = value; format = "nexus";         } 
62                                 if (key == "clustal" )  { clustalfile = value; inputFileName = value; fileroot = value; format = "clustal"; }
63                                 if (key == "tree" )             { treefile = value; inputFileName = value; fileroot = value; format = "tree";           }
64                                 if (key == "shared" )   { sharedfile = value; inputFileName = value; fileroot = value; format = "sharedfile";   }
65                                 if (key == "name" )             { namefile = value;             }
66                                 if (key == "order" )    { orderfile = value;    }
67                                 if (key == "group" )    { groupfile = value;    }
68                                 if (key == "cutoff" )           { cutoff = value;               }
69                                 if (key == "precision" )        { precision = value;    }
70                                 if (key == "iters" )            { iters = value;                }
71                                 if (key == "jumble" )           { jumble = value;               }
72                                 if (key == "freq" )                     { freq = value;                 }
73                                 if (key == "method" )           { method = value;               }
74                                 if (key == "fileroot" )         { fileroot = value;             }
75                                 if (key == "abund" )        { abund = value;        }
76                                 if (key == "random" )           { randomtree = value;   }
77                                 if (key == "calc")                      { calc = value;                 }
78                                 if (key == "step")                      { step = value;                 }
79                                 if (key == "form")                      { form = value;                 }
80                                 if (key == "sorted")            { sorted = value;               }
81                                 if (key == "vertical")          { vertical = value;             }
82                                 if (key == "trump")                 { trump = value;            }
83                                 if (key == "filter")            { filter = value;               }
84                                 if (key == "soft")                  { soft = value;                 }
85                                 if (key == "scale")                     { scale = value;                }
86                                 if (key == "ends" )                     { ends = value;                 }
87                                 if (key == "processors" )       { processors = value;   }
88                                 if (key == "size" )         { size = value;         }
89                                 if (key == "template")          { templatefile = value; }
90                                 if (key == "search")            { search = value;               }
91                                 if (key == "ksize")                     { ksize = value;                }
92                                 if (key == "align")                 { align = value;            }
93                                 if (key == "match")                     { match = value;                }
94                                 if (key == "mismatch")          { mismatch = value;         }
95                                 if (key == "gapopen")           { gapopen = value;              }
96                                 if (key == "gapextend" )        { gapextend = value;    }
97                                 
98                                 if (key == "line") {//stores lines to be used in a set
99                                         lines.clear();
100                                         labels.clear();
101                                         line = value;
102                                         label = "";
103                                         splitAtDash(value, lines);
104                                         allLines = 0;
105                                 }
106                                 if (key == "label") {//stores labels to be used in a set
107                                         labels.clear();
108                                         lines.clear();
109                                         label = value;
110                                         line = "";
111                                         splitAtDash(value, labels);
112                                         allLines = 0;
113                                 }
114
115                                 if (key == "groups") {//stores groups to be used in a vector
116                                         Groups.clear();
117                                         groups = value;
118                                         splitAtDash(value, Groups);
119                                 }
120
121                         }
122                         
123                         //saves the last parameter
124                         value = optionText;
125                         splitAtEquals(key, value);
126                         if (key == "phylip" )   { phylipfile = value; inputFileName = value; fileroot = value; format = "phylip";       }
127                         if (key == "column" )   { columnfile = value; inputFileName = value; fileroot = value; format = "column";       }
128                         if (key == "list" )             { listfile = value; inputFileName = value; fileroot = value; format = "list";           }
129                         if (key == "rabund" )   { rabundfile = value; inputFileName = value; fileroot = value; format = "rabund";       }
130                         if (key == "sabund" )   { sabundfile = value; inputFileName = value; fileroot = value; format = "sabund";       }
131                         if (key == "fasta" )    { fastafile = value; inputFileName = value; fileroot = value; format = "fasta";         }
132                         if (key == "nexus" )    { nexusfile = value; inputFileName = value; fileroot = value; format = "nexus";         }
133                         if (key == "clustal" )  { clustalfile = value; inputFileName = value; fileroot = value; format = "clustal"; } 
134                         if (key == "tree" )             { treefile = value; inputFileName = value; fileroot = value; format = "tree";           } 
135                         if (key == "shared" )   { sharedfile = value; inputFileName = value; fileroot = value; format = "sharedfile";   } 
136                         if (key == "name" )             { namefile = value;             }
137                         if (key == "order" )    { orderfile = value;    }
138                         if (key == "group" )    { groupfile = value;    }
139                         if (key == "cutoff" )           { cutoff = value;               }
140                         if (key == "precision" )        { precision = value;    }
141                         if (key == "iters" )            { iters = value;                }
142                         if (key == "jumble" )           { jumble = value;               }
143                         if (key == "freq" )                     { freq = value;                 }
144                         if (key == "method" )           { method = value;               }
145                         if (key == "fileroot" )         { fileroot = value;             }
146                         if (key == "abund" )        { abund = value;        }
147                         if (key == "random" )           { randomtree = value;   }
148                         if (key == "calc")                      { calc = value;                 }
149                         if (key == "step")                      { step = value;                 }
150                         if (key == "form")                      { form = value;                 }
151                         if (key == "sorted")            { sorted = value;               }
152                         if (key == "vertical")          { vertical = value;             }
153                         if (key == "trump")                 { trump = value;            }
154                         if (key == "filter")            { filter = value;               }
155                         if (key == "soft")                  { soft = value;                 }
156                         if (key == "scale")                     { scale = value;                }
157                         if (key == "ends" )                     { ends = value;                 }
158                         if (key == "processors" )       { processors = value;   }
159                         if (key == "size" )         { size = value;         }
160                         if (key == "template")          { templatefile = value; }
161                         if (key == "search")            { search = value;               }
162                         if (key == "ksize")                     { ksize = value;                }
163                         if (key == "align")                 { align = value;            }
164                         if (key == "match")                     { match = value;                }
165                         if (key == "mismatch")          { mismatch = value;         }
166                         if (key == "gapopen")           { gapopen = value;              }
167                         if (key == "gapextend" )        { gapextend = value;    }
168
169                         if (key == "line") {//stores lines to be used in a vector
170                                 lines.clear();
171                                 labels.clear();
172                                 line = value;
173                                 label = "";
174                                 if (line != "all") {  splitAtDash(value, lines);  allLines = 0;  }
175                                 else { allLines = 1;  }
176                         }
177                         
178                         if (key == "label") {//stores lines to be used in a vector
179                                 labels.clear();
180                                 lines.clear();
181                                 label = value;
182                                 line = "";
183                                 if (label != "all") {  splitAtDash(value, labels);  allLines = 0;  }
184                                 else { allLines = 1;  }
185                         }
186                         
187                         if (key == "groups") {//stores groups to be used in a vector
188                                         Groups.clear();
189                                         groups = value;
190                                         splitAtDash(value, Groups);
191                         }
192                 }
193                 
194                 //set format for shared
195                 if ((listfile != "") && (groupfile != "")) { format = "shared"; }
196                 if ((phylipfile != "") && (groupfile != "")) { format = "matrix"; }
197                                 
198                 //input defaults for calculators
199                 if (commandName == "collect.single") {
200
201                         if ((calc == "default") || (calc == "")) { calc = "sobs-chao-ace-jack-shannon-npshannon-simpson-efron-boneh-solow-shen"; }
202                         Estimators.clear();
203                         splitAtDash(calc, Estimators); 
204                 }
205                 if (commandName == "rarefaction.single") {
206                         if ((calc == "default") || (calc == "")) { calc = "sobs"; }
207                         Estimators.clear();
208                         splitAtDash(calc, Estimators); 
209                 }
210                 if (commandName == "collect.shared") {
211
212                         if ((calc == "default") || (calc == "")) { calc = "sharedsobs-sharedchao-sharedace-jabund-sorabund-jclass-sorclass-jest-sorest-thetayc-thetan"; }
213                         Estimators.clear();
214                         splitAtDash(calc, Estimators); 
215                 }
216                 if (commandName == "summary.single") {
217                         if ((calc == "default") || (calc == "")) { calc = "sobs-chao-ace-jack-shannon-npshannon-simpson-efron-boneh-solow-shen"; }
218                         Estimators.clear();
219                         splitAtDash(calc, Estimators); 
220                 }
221                 if (commandName == "summary.shared") {
222                         if ((calc == "default") || (calc == "")) { calc = "sharedsobs-sharedchao-sharedace-jabund-sorabund-jclass-sorclass-jest-sorest-thetayc-thetan"; }
223                         Estimators.clear();
224                         splitAtDash(calc, Estimators); 
225                 }
226                 if (commandName == "rarefaction.shared") {
227                         if ((calc == "default") || (calc == "")) { calc = "sharedobserved"; }
228                         Estimators.clear();
229                         splitAtDash(calc, Estimators); 
230                 }
231                 if (commandName == "dist.seqs") {
232                         if ((calc == "default") || (calc == "")) {  calc = "onegap";  }
233                         Estimators.clear();
234                         splitAtDash(calc, Estimators); 
235                 }
236                 if (commandName == "venn") {
237                         if ((calc == "default") || (calc == "")) { 
238                                 if (format == "list") { calc = "sobs"; }
239                                 else { calc = "sharedsobs"; }
240                         }
241                         Estimators.clear();
242                         splitAtDash(calc, Estimators); 
243                 }
244                 if ((commandName == "tree.shared") || (commandName == "bootstrap.shared")) {
245                         if (calc != "") { 
246                                 Estimators.clear();
247                                 splitAtDash(calc, Estimators);                  
248                         }else { cout << "You have not specified any calculators." << endl; }
249                 }
250
251
252                 //if you have done a read.otu with a groupfile but don't want to use it anymore because you want to do single commands
253                 if ((commandName == "collect.single") || (commandName == "rarefaction.single") || (commandName == "summary.single")) {
254                         if (listfile != "") { format = "list"; }
255                         else if (sabundfile != "") { format = "sabund"; }
256                         else if (rabundfile != "") { format = "rabund"; }
257                 }
258         }
259         catch(exception& e) {
260                 cout << "Standard Error: " << e.what() << " has occurred in the GlobalData class Function parseGlobalData. Please contact Pat Schloss at pschloss@microbio.umass.edu." << "\n";
261                 exit(1);
262         }
263         catch(...) {
264                 cout << "An unknown error has occurred in the GlobalData class function parseGlobalData. Please contact Pat Schloss at pschloss@microbio.umass.edu." << "\n";
265                 exit(1);
266         }
267 }
268 /*******************************************************/
269
270 /******************************************************/
271 // These functions give you the option parameters of the commands
272 string GlobalData::getPhylipFile()              {       return phylipfile;      }
273 string GlobalData::getColumnFile()              {       return columnfile;      }
274 string GlobalData::getListFile()                {       return listfile;        }
275 string GlobalData::getRabundFile()              {       return rabundfile;      }
276 string GlobalData::getSabundFile()              {       return sabundfile;      }
277 string GlobalData::getNameFile()                {       return namefile;        }
278 string GlobalData::getGroupFile()               {       return groupfile;       }
279 string GlobalData::getOrderFile()               {       return orderfile;       }
280 string GlobalData::getTreeFile()                {       return treefile;        }
281 string GlobalData::getSharedFile()              {       return sharedfile;      }
282 string GlobalData::getFastaFile()               {       return fastafile;       }
283 string GlobalData::getNexusFile()               {       return nexusfile;       }
284 string GlobalData::getClustalFile()     {   return clustalfile; }
285 string GlobalData::getCutOff()                  {       return cutoff;          }
286 string GlobalData::getFormat()                  {       return format;          }
287 string GlobalData::getPrecision()               {       return precision;       }
288 string GlobalData::getMethod()                  {       return method;          }
289 string GlobalData::getFileRoot()                {       return fileroot;        }
290 string GlobalData::getIters()                   {       return iters;           }
291 string GlobalData::getJumble()                  {       return jumble;          }
292 string GlobalData::getFreq()                    {       return freq;            }
293 string GlobalData::getAbund()           {   return abund;       }
294 string GlobalData::getRandomTree()              {       return randomtree;      }
295 string GlobalData::getGroups()                  {       return groups;          }
296 string GlobalData::getStep()                    {       return step;            }
297 string GlobalData::getForm()                    {       return form;            }
298 string GlobalData::getSorted()                  {       return sorted;          }
299 string GlobalData::getTrump()                   {   return trump;       }
300 string GlobalData::getSoft()                    {   return soft;                }
301 string GlobalData::getFilter()                  {   return filter;              }
302 string GlobalData::getScale()                   {       return scale;           }
303 string GlobalData::getEnds()                    {   return ends;                }
304 string GlobalData::getProcessors()              {       return processors;      }
305 string GlobalData::getSize()            {   return size;        }
306 string GlobalData::getTemplateFile()    {       return templatefile;}
307 string GlobalData::getSearch()                  {       return search;          }
308 string GlobalData::getKSize()                   {       return ksize;           }
309 string GlobalData::getAlign()                   {       return align;           }
310 string GlobalData::getMatch()                   {       return match;           }
311 string GlobalData::getMismatch()                {       return mismatch;        }
312 string GlobalData::getGapopen()                 {       return gapopen;         }
313 string GlobalData::getGapextend()               {       return gapextend;       }
314
315
316 void GlobalData::setListFile(string file)       {       listfile = file;        inputFileName = file;}
317 void GlobalData::setRabundFile(string file)     {       rabundfile = file;      inputFileName = file;}
318 void GlobalData::setSabundFile(string file)     {       sabundfile = file;      inputFileName = file;}
319 void GlobalData::setPhylipFile(string file)     {       phylipfile = file;    inputFileName = file;}
320 void GlobalData::setColumnFile(string file)     {       columnfile = file;    inputFileName = file;}
321 void GlobalData::setGroupFile(string file)              {       groupfile = file;       }
322 void GlobalData::setSharedFile(string file)             {       sharedfile = file;      inputFileName = file; fileroot = file;}
323 void GlobalData::setNameFile(string file)               {       namefile = file;                }
324 void GlobalData::setFormat(string Format)               {       format = Format;                }
325 void GlobalData::setRandomTree(string Random)   {       randomtree = Random;    }
326 void GlobalData::setGroups(string g)                    {       groups = g;                             }
327 void GlobalData::setCalc(string Calc)                   {       calc = Calc;                    }
328 void GlobalData::setEnds(string e)                              {   ends = e;                           }
329 void GlobalData::setProcessors(string p)                {       processors = p;                 }
330
331
332 /*******************************************************/
333
334 /******************************************************/
335 GlobalData::GlobalData() {
336         //option definitions should go here...
337         helpRequest = "";
338         clear();
339         gListVector == NULL;            
340         gSparseMatrix == NULL;  
341 }
342 /*******************************************************/
343
344 /******************************************************/
345 void GlobalData::clear() {
346         //option definitions should go here...
347         phylipfile              =       "";
348         columnfile              =       "";
349         listfile                =       "";
350         rabundfile              =       "";
351         sabundfile              =       "";
352         namefile                =       "";
353         groupfile               =       ""; 
354         orderfile               =       "";
355         fastafile               =   "";
356         nexusfile               =   "";
357         clustalfile             =   "";
358         treefile                =       "";
359         sharedfile              =       "";
360         templatefile    =       "";
361         cutoff                  =       "10.00";
362         format                  =       "";
363         precision               =       "100";
364         iters                   =       "1000"; 
365         line                    =   "";
366         label                   =       "";
367         groups                  =       "";
368         jumble                  =       "1";    //0 means don't jumble, 1 means jumble.
369         randomtree              =       "";  //"" means user will enter some user trees, "outputfile" means they just want the random tree distribution to be outputted to outputfile.
370         freq                    =       "100";
371         method                  =       "furthest";
372         fileroot                =       "";
373         abund           =   "10";
374         step                    =       "0.01";
375         form                    =       "integral";
376         sorted                  =       "T";  //F means don't sort, T means sort.
377         vertical        =   "";         
378         trump           =   "";         
379         filter          =   "";         
380         soft            =   ""; 
381         scale                   =       "log10";
382         ends                    =   "T";  //yes
383         processors              =       "1";
384         size            =   "1000";
385         search                  =       "suffix";
386         ksize                   =       "7";
387         align                   =       "blast";
388         match                   =       "1.0";
389         mismatch                =       "-1.0";
390         gapopen                 =       "-5.0";
391         gapextend               =       "-2.0";
392 }
393
394 //*******************************************************/
395
396 /******************************************************/
397 void GlobalData::reset() {
398         cutoff                  =       "10.00";
399         precision               =       "100";
400         iters                   =       "1000"; 
401         groups                  =       "";
402         jumble                  =       "1";    //0 means don't jumble, 1 means jumble.
403         sorted                  =       "T";  //F means don't sort, T means sort.
404         randomtree              =       "";  //"" means user will enter some user trees, "outputfile" means they just want the random tree distribution to be outputted to outputfile.
405         freq                    =       "100";
406         method                  =       "furthest";
407         calc                    =       "";
408         abund                   =   "10";
409         step                    =       "0.01";
410         form                    =       "integral";
411         ends                    =   "T";
412         processors              =       "1";
413         size            =   "1000";
414         search                  =       "suffix";
415         ksize                   =       "7";
416         align                   =       "blast";
417         match                   =       "1.0";
418         mismatch                =       "-1.0";
419         gapopen                 =       "-5.0";
420         gapextend               =       "-2.0";
421 }
422 /*******************************************************/
423
424 /******************************************************/
425 GlobalData::~GlobalData() {
426         _uniqueInstance = 0;
427         if(gListVector != NULL)         {       delete gListVector;             }
428         if(gSparseMatrix != NULL)       {       delete gSparseMatrix;   }
429         if(gorder != NULL)                      {       delete gorder;          }
430 }
431 /*******************************************************/
432
433 /*******************************************************/
434 void GlobalData::parseTreeFile() {
435         //only takes names from the first tree and assumes that all trees use the same names.
436         try {
437                 string filename = treefile;
438                 ifstream filehandle;
439                 openInputFile(filename, filehandle);
440                 int c, comment;
441                 comment = 0;
442                 
443                 //if you are not a nexus file 
444                 if ((c = filehandle.peek()) != '#') {  
445                         while((c = filehandle.peek()) != ';') { 
446                                 while ((c = filehandle.peek()) != ';') {
447                                         // get past comments
448                                         if(c == '[') {
449                                                 comment = 1;
450                                         }
451                                         if(c == ']'){
452                                                 comment = 0;
453                                         }
454                                         if((c == '(') && (comment != 1)){ break; }
455                                         filehandle.get();
456                                 }
457
458                                 readTreeString(filehandle); 
459                         }
460                 //if you are a nexus file
461                 }else if ((c = filehandle.peek()) == '#') {
462                         string holder = "";
463                                         
464                         // get past comments
465                         while(holder != "translate" && holder != "Translate"){  
466                                 if(holder == "[" || holder == "[!"){
467                                         comment = 1;
468                                 }
469                                 if(holder == "]"){
470                                         comment = 0;
471                                 }
472                                 filehandle >> holder; 
473         
474                                 //if there is no translate then you must read tree string otherwise use translate to get names
475                                 if(holder == "tree" && comment != 1){   
476                                         //pass over the "tree rep.6878900 = "
477                                         while (((c = filehandle.get()) != '(') && ((c = filehandle.peek()) != EOF) ) {;}
478
479                                         if (c == EOF ) { break; }
480                                         filehandle.putback(c);  //put back first ( of tree.
481                                         readTreeString(filehandle);     
482                                         break;
483                                 }
484                         }
485                         
486                         //use nexus translation rather than parsing tree to save time
487                         if ((holder == "translate") || (holder == "Translate")) {
488
489                                 string number, name, h;
490                                 h = ""; // so it enters the loop the first time
491                                 while((h != ";") && (number != ";")) { 
492                                         filehandle >> number;
493                                         filehandle >> name;
494         
495                                         //c = , until done with translation then c = ;
496                                         h = name.substr(name.length()-1, name.length()); 
497                                         name.erase(name.end()-1);  //erase the comma
498                                         Treenames.push_back(number);
499                                 }
500                                 if (number == ";") { Treenames.pop_back(); }  //in case ';' from translation is on next line instead of next to last name
501                         }
502                 }
503                 
504         }
505         catch(exception& e) {
506                 cout << "Standard Error: " << e.what() << " has occurred in the GlobalData class Function parseTreeFile. Please contact Pat Schloss at pschloss@microbio.umass.edu." << "\n";
507                 exit(1);
508         }
509         catch(...) {
510                 cout << "An unknown error has occurred in the GlobalData class function parseTreeFile. Please contact Pat Schloss at pschloss@microbio.umass.edu." << "\n";
511                 exit(1);
512         }               
513 }
514 /*******************************************************/
515
516 /*******************************************************/
517 void GlobalData::readTreeString(ifstream& filehandle)   {
518         try {
519                 int c;
520                 string name; //k
521                 
522                 while((c = filehandle.peek()) != ';') { 
523                                 //if you are a name
524                         if ((c != '(') && (c != ')') && (c != ',') && (c != ':') && (c != '\n') && (c != '\t') && (c != 32)) { //32 is space
525                                 name = "";
526                                 c = filehandle.get();
527         //              k = c;
528 //cout << k << endl;
529                                 while ((c != '(') && (c != ')') && (c != ',') && (c != ':') && (c != '\n') && (c != 32) && (c != '\t')) {                       
530                                         name += c;
531                                         c = filehandle.get();
532                 //      k = c;
533 //cout << " in name while " << k << endl;
534                                 }
535                                 
536 //cout << "name = " << name << endl;
537                                 Treenames.push_back(name);
538                                 filehandle.putback(c);
539 //k = c;
540 //cout << " after putback" <<  k << endl;
541                         } 
542                         
543                         if (c  == ':') { //read until you reach the end of the branch length
544                                 while ((c != '(') && (c != ')') && (c != ',') && (c != ';') && (c != '\n') && (c != '\t') && (c != 32)) {
545                                         c = filehandle.get();
546                                 //      k = c;
547         //cout << " in branch while " << k << endl;
548                                 }
549                                 filehandle.putback(c);
550                         }
551                         c = filehandle.get();
552                         if (c == ';') { break; }
553                 //      k = c;
554 //cout << k << endl;
555
556                 }
557         }
558         catch(exception& e) {
559                 cout << "Standard Error: " << e.what() << " has occurred in the GlobalData class Function parseTreeFile. Please contact Pat Schloss at pschloss@microbio.umass.edu." << "\n";
560                 exit(1);
561         }
562         catch(...) {
563                 cout << "An unknown error has occurred in the GlobalData class function parseTreeFile. Please contact Pat Schloss at pschloss@microbio.umass.edu." << "\n";
564                 exit(1);
565         }               
566 }       
567
568 /*******************************************************/
569
570 /*******************************************************/
571
572