5 * Created by Thomas Ryabin on 4/8/09.
6 * Copyright 2009 Schloss Lab UMASS Amherst. All rights reserved.
10 #include "goodscoverage.h"
11 #include "calculator.h"
13 /**********************************************************/
15 EstOutput GoodsCoverage::getValues(SAbundVector* rank){
19 double numSingletons = rank->get(1);
20 double totalIndividuals = rank->getNumSeqs();
22 data[0] = 1 - numSingletons/totalIndividuals;
24 if (isnan(data[0]) || isinf(data[0])) { data[0] = 0; }
29 m->errorOut(e, "GoodsCoverage", "getValues");
34 /***********************************************************************/