cov_D2st#
- pybrops.model.vmat.util.cov_D2st(r, nself, t)[source]#
Calculate a D_2 matrix. This matrix represents a linkage disequilibrium prototype for two recombination events prior to selfing or random intermating.
- Parameters:
r (numpy.ndarray) – Recombination probability matrix.
nself (int, inf) –
Selfing generation number to derive gametes from.
Example
Description
nself = 0
Derive gametes from F1
nself = 1
Derive gametes from F2
nself = 2
Derive gametes from F3
...
etc.
nself = inf
Derive gametes from SSD
Remark:
’s’ takes priority over ‘t’. If s > 0, ‘t’ calculations are not performed.
t (int, inf) –
Random intermating generation number to derive gametes from.
Example
Description
t = 0
Derive gametes from F1
t = 1
Derive gametes from (F1 x F1)
t = 2
Derive gametes from (F1 x F1) x (F1 x F1)
...
etc.
t = inf
Derive gametes from unlimited random intermating
Remark:
’s’ takes priority over ‘t’. If s > 0, ‘t’ calculations are not performed.
- Returns:
D_2 – A D_2 matrix.
- Return type:
numpy.ndarray