twoLocusJacquard {IBDsim} | R Documentation |
Estimating two-locus Jacquard coefficients
Description
Estimates by simulation the two-locus version of Jacquard's condensed identity coefficients for a pairwise relationship.
Usage
twoLocusJacquard(x, ind1, ind2, rho=NULL, cM=NULL, Nsim, verbose=TRUE,...)
Arguments
x |
A pedigree in the form of a |
ind1 , ind2 |
Numeric ID labels of the two individuals. |
rho |
NULL, or a number in the interval [0, 0.5]: the recombination fraction between the two loci. If non-NULL, it is converted to centiMorgan using Haldanes map function: |
cM |
NULL, or a non-negative number: the distance in centiMorgan between the two loci. The numeric |
Nsim |
The number of simulations to be performed. |
verbose |
A logical. |
... |
Further arguments to be passed on to |
Details
As in the case of IBD coefficients (see twoLocusIBD
), we can generalise Jacquard's identity coefficients to two loci: Given any pair of individuals, and any pair of autosomal loci, we define the two-locus Jacquard coefficient \Delta[i,j]
(where 1 \le i,j \le 9
) by
\Delta[i,j] = Pr(Jacquard state \Sigma[i] at locus 1, and state \Sigma[j] at locus 2).
Value
A numerical 9*9 matrix. The entry in row a
and column b
is the estimate of \Delta[a-1, b-1]
defined above.
Author(s)
Magnus Dehli Vigeland
See Also
jacquard
, oneLocusIBD
, twoLocusIBD
, oneLocusJacquard
Examples
### Siblings whose parents are full siblings.
x = fullSibMating(generations=2)
Nsim = 100 # (increase to improve accuracy)
# Estimate of the 9 identity coefficients
j_est = oneLocusJacquard(x, ind1=5, ind2=6, Nsim=Nsim, seed=123)
### Two-locus Jacquard coefficients
# Completely linked loci
rho = 0
j2_linked = twoLocusJacquard(x, ind1=5, ind2=6, rho=rho, Nsim=Nsim, seed=123)
stopifnot(identical(diag(j2_linked), j_est))
# Completely unlinked
rho = 0.5
j2_unlinked = twoLocusJacquard(x, ind1=5, ind2=6, rho=rho, Nsim=Nsim, seed=123)
stopifnot(identical(j2_unlinked, outer(j_est, j_est)))