View source: R/Labelling_and_plotting_functions.R
| label_relatives | R Documentation |
Assigns standard pedigree relationship labels (e.g., Parent, Child, Sibling, Grandparent, Cousin)
to all pairs of individuals based on their generational distances (gen.x, gen.y)
and kinship coefficients (k), typically produced by get_generations().
label_relatives(tbl)
tbl |
A tibble or data frame containing at least the following columns:
|
This function derives descriptive relationship labels using generational differences and kinship patterns. The labels are written in a short-hand notation, an explaination of a subset is given below:
P - Parent
Ch - Child
S - Sibling
GP - Grandparent
Pib - "Pibling" (parental sibling; aunt/uncle)
Nib - "Nibling" (sibling's child; niece/nephew)
GCh - Grandchild
GPib - Grandpibling (grandparent's sibling)
GNib - Grandnibling (sibling's grandchild)
C - Cousin
1C1R - First Cousin Once Removed
2C2R - Second Cousin Twice Removed
H prefix - Half relationships (e.g., HS for Half-Sibling)
A tibble with the following columns:
Column with family identifier (typically the proband's id).
Identifier for the first individual.
Identifier for the second individual.
Generational distance for id1.
Generational distance for id2.
Kinship coefficient between the two individuals.
Assigned relationship label (e.g., "S", "P", "1C", "H1C", "2GP", etc.).
get_generations() for computing the generational and kinship inputs used by this function.
# see vignette on identifying and labelling relatives
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.