Commit f821dc76 authored by zhanxw's avatar zhanxw
Browse files

add option afMethod=kinship/mean for grammagamma model

parent a41c29fa
......@@ -64,7 +64,23 @@ int ModelManager::create(const std::string& modelType,
} else if (modelName == "famlrt") {
model.push_back(new SingleVariantFamilyLRT);
} else if (modelName == "famgrammargamma") {
model.push_back(new SingleVariantFamilyGrammarGamma);
std::string afMethod;
parser.assign("af", &afMethod, "mean");
if (afMethod == "kinship") {
logger->info(
"FamGrammarGamma will output kinship-adjusted allele frequencies");
model.push_back(
new SingleVariantFamilyGrammarGamma(GrammarGamma::AF_KINSHIP));
} else if (afMethod == "mean") {
model.push_back(
new SingleVariantFamilyGrammarGamma(GrammarGamma::AF_MEAN));
} else {
logger->info(
"FamGrammarGamma cannot recoginized specified kinship calculation "
"method [ %s ], exit...",
afMethod.c_str());
exit(1);
}
} else if (modelName == "firth") {
model.push_back(new SingleVariantFirthTest);
} else if (modelName == "mtscore") {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment