Description Usage Arguments Details Value Author(s) References See Also Examples
MCIBD
estimates the IBD matrix at a given locus or the epistatic IBD matrix for two linked loci. Monte Carlo sampling is used to approach to the matrix estimator, where the output file from cnF2freq
is required. Segregation of the founder alleles can be set up in the estimation. Parallelzation is available using snowfall
package if executing on a multi-core computer or cluster.
1 2 3 |
loci |
typically an integer specifying a test locus, or a vector containing two linked loci. |
n.F2 |
an integer telling the number of F2 individuals in the pedigree. |
pedigree |
a matrix or data.frame or file containing pedigree information. For file (when |
cnF2freq.out |
a matrix or data.frame containing the output probabilities from cnF2freq. For file (when |
IBD.type |
a string specifying the output type of IBD matrix, |
output.Z |
a string indicates the type of output. If |
read.file |
logical. If |
segregation |
a vector specifying the segregation of founder alleles. (See Details.) |
mc.size |
an integer setting the sample size of the Monte Carlo sampling for one CPU. |
hpc |
logical. If |
n.cpus |
an integer telling the number of cores that parallelization is executed on. Only useful when |
To set up the segregation
of the founder alleles, suppose that we have m founder(s) from one line and n from another line. Then in total there are 2 * (m + n) alleles needed to be set up. According to the order in the pedigree information file, these alleles for the founders should be filled in segregation
as a vector with length 2 * (m + n). For instance, if there is one male in one line and three females in another line, the vector might be created like c(1,1,2,2,3,3,2,3)
, which means that the male has two identical alleles whereas the genotypes of the females are (2,2), (3,3) and (2,3), respectively. If NULL
, all the founder alleles are assumed to be different from each other.
An output IBD matrix is saved in the working directory as a file named by the loci with extension .ibd
.
Xia Shen
Shen, X., Nettelblad, C., Ronnegard, L. and Carlborg, O. (2009). Flexible Identity-By-Descent Matrix Estimation with Given Base Generation Structures in F2 Intercross Designs. Package Vignette.
cnF2freq
, MCIBD.chro
, MCIBD.epi2chro
, MCIBD-package
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 | data(pedigree)
data(probabilities)
## Calculation on one CPU
MCIBD(loci = 80, n.F2 = 191, pedigree = pedigree,
cnF2freq.out = probabilities, mc.size = 5)
## IBD matrix of dimension 191 x 191 at locus 80 is accomplished,
## where 5 imputes were sampled.
## Calculation on 2 CPUs with segregation of the founder alleles
MCIBD(loci = 90, n.F2 = 191, pedigree = pedigree,
segregation = c(rep(1,4),rep(2,16)),
cnF2freq.out = probabilities, mc.size = 5, hpc = TRUE, n.cpus = 2)
## IBD matrix of dimension 191 x 191 at locus 90 is accomplished,
## where 10 imputes were sampled.
## Calculation of epistatic IBD matrix
MCIBD(loci = c(88, 99), n.F2 = 191, pedigree = pedigree,
segregation = c(rep(1,4),rep(2,16)),
cnF2freq.out = probabilities, mc.size = 5, hpc = TRUE, n.cpus = 2)
## IBD matrix of dimension 191 x 191 for linked lici 88 and 99 is accomplished,
## where 10 imputes were sampled.
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.