kinship
jennifer
import "@deckyard/forensicgenetics/kinship.j" as kinship;Pairwise relationship likelihood ratios and trio paternity. It takes the core's Profile, Genotype and FrequencyDb. Signatures, the relationship and mutation constants, and struct fields are in the Cheatsheet.
Conventions
θ = 0throughout. See Theta.HALF_SIBLINGS,GRANDPARENTandAVUNCULARhave equal coefficients and give equal LRs.kinshipLRandkinshipLRAgainstmultiply overpairLoci;paternityIndex,paternityIndexWithandinconsistentLociovertrioLoci. Other loci are ignored.paternityIndexusesDEFAULT_MUTATION(rate 0.002, decay 0.1, a placeholder). The model applies to the alleged father's transmission only.mutationProbabilitycountsk = max(1, round(|value(s) - value(t)|))steps; at rate 0 any change has probability 0 without counting steps.relationshipaccepts coefficients in[0, 1]summing to 1 within 1e-9;mutationModelandwithLocusRateaccept rates and decay in[0, 1);probabilityOfPaternityPriora prior in(0, 1).
Formulae: Formulae and sources. Guides: Kinship, Paternity.
Errors
Error{kind: "kinship"}, thrown for:
- IBD coefficients outside
[0, 1]or not summing to 1 - a mutation rate or decay outside
[0, 1) - a step count between alleles that are not repeat counts, when the rate is above 0
- a genotype pair, or a trio, at different loci
- an alternative hypothesis giving the observed pair probability zero (
kinshipLRAtand the functions built on it) - no shared locus for a pair or a trio
- a maternal exclusion (the mother can transmit neither of the child's alleles)
- a negative CPI, or a prior outside
(0, 1)
A locus the database lacks surfaces as the core's "forensicgenetics" error.