Description Usage Arguments Value
The intended use of this is to update the marriage posteriors after an individual has
been moved from one sibship to another. So, for example, if you moved an individual
from sibship 40 to sibship 291 (as subscripted in R) then you would want to run this
with bz_idx
equal to the column of sibship 39, and then run it again with it equal
to the column of 290, after you had updated the LMMFS
for each of those.
1 | update_marriage_posteriors_in_place(ML, MP, Pri, NGS, bz_idx)
|
ML |
the marriage likelihoods matrix |
MP |
the marriage posteriors matrix that is to be updated |
Pri |
the joint prior probbabilities of the parent pair |
NGS |
Number of genotypic states. For pairs of parents, for example, this will be 9. |
bz_idx |
An integer vector holding the BASE-0 index of the columns of MP that needs updating. Note that this is not the index of the sibhip, but rather the column that sibship occupies in MP. That will be something like FSL[Indiv]$LMMI_Idx that |
This returns the value of the index of the last marriage that it updated. It does this so I can check some things. It modifies MP in place via call by reference. Our goal here is to make updates without copying a lot of memory.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.