/********************************************************************/
void ValidCalculators::initialMatrix() {
try {
- matrix["jabund"] = "jabund";
+ matrix["sharedsobs"] = "sharedsobs";
+ matrix["sharedchao"] = "sharedchao";
+ matrix["sharedace"] = "sharedace";
+ matrix["jabund"] = "jabund";
matrix["sorabund"] = "sorabund";
- matrix["jclass"] = "jclass";
+ matrix["jclass"] = "jclass";
matrix["sorclass"] = "sorclass";
matrix["jest"] = "jest";
- matrix["sorest"] = "sorest";
+ matrix["sorest"] = "sorest";
matrix["thetayc"] = "thetayc";
- matrix["thetan"] = "thetan";
+ matrix["thetan"] = "thetan";
+ matrix["kstest"] = "kstest";
+ matrix["whittaker"] = "whittaker";
+ matrix["sharednseqs"] = "sharednseqs";
+ matrix["ochiai"] = "ochiai";
+ matrix["anderberg"] = "anderberg";
+ matrix["kulczynski"] = "kulczynski";
+ matrix["kulczynskicody"] = "kulczynskicody";
+ matrix["lennon"] = "lennon";
matrix["morisitahorn"] = "morisitahorn";
- matrix["braycurtis"] = "braycurtis";
+ matrix["braycurtis"] = "braycurtis";
+ matrix["odum"] = "odum";
+ matrix["canberra"] = "canberra";
+ matrix["structeuclidean"] = "structeuclidean";
+ matrix["structchord"] = "structchord";
+ matrix["hellinger"] = "hellinger";
+ matrix["manhattan"] = "manhattan";
+ matrix["structpearson"] = "structpearson";
+ matrix["structkulczynski"] = "structkulczynski";
+ matrix["structchi2"] = "structchi2";
+ matrix["soergel"] = "soergel";
+ matrix["spearman"] = "spearman";
+ matrix["speciesprofile"] = "speciesprofile";
+ matrix["hamming"] = "hamming";
+ matrix["gower"] = "gower";
+ matrix["memchi2"] = "memchi2";
+ matrix["memchord"] = "memchord";
+ matrix["memeuclidean"] = "memeuclidean";
+ matrix["mempearson"] = "mempearson";
+
}
catch(exception& e) {
m->errorOut(e, "ValidCalculator", "initialMatrix");
}
}
/********************************************************************/
+string ValidCalculators::printCalc(string parameter) {
+ try{
+ string output = "The available estimators for calc are ";
+ //are you looking for a calculator for a single parameter
+ if (parameter == "single") {
+ for (it = single.begin(); it != single.end(); it++) {
+ output += it->first + ", ";
+ }
+ //are you looking for a calculator for a shared parameter
+ }else if (parameter == "shared") {
+ for (it = shared.begin(); it != shared.end(); it++) {
+ output += it->first + ", ";
+ }
+ //are you looking for a calculator for a rarefaction parameter
+ }else if (parameter == "rarefaction") {
+ for (it = rarefaction.begin(); it != rarefaction.end(); it++) {
+ output += it->first + ", ";
+ }
+ //are you looking for a calculator for a summary parameter
+ }else if (parameter == "summary") {
+ for (it = summary.begin(); it != summary.end(); it++) {
+ output += it->first + ", ";
+ }
+ //are you looking for a calculator for a sharedsummary parameter
+ }else if (parameter == "sharedsummary") {
+ for (it = sharedsummary.begin(); it != sharedsummary.end(); it++) {
+ output += it->first + ", ";
+ }
+ }else if (parameter == "sharedrarefaction") {
+ for (it = sharedrarefaction.begin(); it != sharedrarefaction.end(); it++) {
+ output += it->first + ", ";
+ }
+ }else if (parameter == "vennsingle") {
+ for (it = vennsingle.begin(); it != vennsingle.end(); it++) {
+ output += it->first + ", ";
+ }
+ }else if (parameter == "vennshared") {
+ for (it = vennshared.begin(); it != vennshared.end(); it++) {
+ output += it->first + ", ";
+ }
+ }else if (parameter == "treegroup") {
+ for (it = treegroup.begin(); it != treegroup.end(); it++) {
+ output += it->first + ", ";
+ }
+ }else if (parameter == "matrix") {
+ for (it = matrix.begin(); it != matrix.end(); it++) {
+ output += it->first + ", ";
+ }
+ }else if (parameter == "heat") {
+ for (it = heat.begin(); it != heat.end(); it++) {
+ output += it->first + ", ";
+ }
+ }else if (parameter == "boot") {
+ for (it = boot.begin(); it != boot.end(); it++) {
+ output += it->first + ", ";
+ }
+ }else if (parameter == "distance") {
+ for (it = distance.begin(); it != distance.end(); it++) {
+ output += it->first + ", ";
+ }
+ }
+
+ //rip off comma
+ output = output.substr(0, output.length()-1);
+ output += "\n";
+
+ return output;
+ }
+ catch(exception& e) {
+ m->errorOut(e, "ValidCalculator", "printCalc");
+ exit(1);
+ }
+}
+/********************************************************************/
+