Description Usage Arguments Details Value
View source: R/anc_match_masks.R
This returns a list of two logical matrices. The first catches the zone that is above the diagonal (when plotted with ind_1 on the x-axis and ind_2 on the y-axis). These correspond to ind_2 being the "older" member of the pair than ind_1. The second catches the zone on the lower diagonal. If the zone spans the diagonal, then each matrix returned in the list is the same.
1 | anc_match_masks(num_generations, R)
|
num_generations |
the number of generations to go back. 0 = self; 1 = to the parents; 2 = to the grandparents; 3 = to the great grandparents, etc. |
R |
the relationship whose zones you want to mask with TRUEs in the output matrices. See below for the possible choices. |
The relationships whose zones we are equipped to deal with go out to n=4 generation,
and are named (and ordered) as follows, which is the order in which they
appear in the package data vector relationship_zone_names
:
Se
: self. This is as far as it goes with num_generations = 0
PO
: parent-offspring
Si
: sibling. This is as far as it goes with num_generations = 1.
GP
: grandparental
A
: avuncular (aunt-niece)
FC
: first cousin. This is as far as it goes with num_generations = 2.
GGP
: great-grandparental
GA
: great-avuncular (great-aunt/great-niece, etc).
FCr1
: first-cousin once removed
SC
: second cousin. This is as far as it goes with num_generations = 3
GGGP
: great-great-grandparental
GGA
: great-great-avuncular
FCr2
: first cousin twice removed
SCr1
: second cousin once removed
TC
: third cousin
At this point the additional zones for num_generations = 3 have not been
implemented.
This function returns a list of two matrices. Each one has FALSEs everywhere except in the zones corresponding to the relationship, where it has TRUEs. As mentioned above, the first matrix captures the zones where ind_2 is the "older" one and the second matrix captures the zones where ind_1 is the "older" one. For the symmetrical relationships (Se, Si, FC, etc.) the two matrices in the list are identical.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.