Skip to content
Snippets Groups Projects
Commit 4b9ee1e0 authored by Empress Sela's avatar Empress Sela
Browse files

Show inbreeding of slaves

parent c76ea8ab
No related branches found
No related tags found
1 merge request!7156Inbreeding coefficient
......@@ -490,6 +490,20 @@ App.Desc.family = (function() {
r.push(`${He} has ${numberWithPlural(slave.sisters, "sister")} and ${numberWithPlural(slave.daughters, "daughter")}.`);
}
if (V.inbreeding && slave.inbreedingCoeff > 0) {
r.push(`${He} is`);
if (slave.inbreedingCoeff >= 0.5)
r.push("extremely");
else if (slave.inbreedingCoeff >= 0.25)
r.push("very");
else if (slave.inbreedingCoeff >= 0.125);
else if (slave.inbreedingCoeff >= 0.0625)
r.push("somewhat");
else
r.push("slightly");
r.push(`inbred, with a CoI of ${slave.inbreedingCoeff}.`);
}
return r.join(" ");
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment