View source: R/poly_cross_simulate.R
poly_cross_simulate | R Documentation |
Simulate an autopolyploid full-sib population with one or two informative parents under random chromosome segregation.
poly_cross_simulate( ploidy, rf.vec, n.mrk, n.ind, hom.allele, draw = FALSE, file = "output.pdf", seed = NULL, width = 12, height = 6, prob.P = NULL, prob.Q = NULL )
ploidy |
ploidy level. Must be an even number |
rf.vec |
vector containing the recombination fractions between adjacent markers. If a single recombination fraction is provided, it is repeated n.mrk-1 times |
n.mrk |
number of markers |
n.ind |
number of individuals in the offspring |
hom.allele |
a list containing the linkage phase information for both parents |
draw |
if |
file |
name of the output file. It is ignored if
|
seed |
random number generator seed (default = NULL) |
width |
the width of the graphics region in inches (default = 12) |
height |
the height of the graphics region in inches (default = 6) |
prob.P |
a vector indicating the proportion of preferential pairing in parent P (currently ignored) |
prob.Q |
a vector indicating the proportion of preferential pairing in parent Q (currently ignored) |
hom.allele.p
and hom.allele.q
are lists of vectors
containing linkage phase configurations. Each vector contains the
numbers of the homologous chromosomes in which the alleles are
located. For instance, a vector containing (1,3,4) means that
the marker has three doses located in the chromosomes 1, 3 and 4. For
zero doses, use 0.
For more sophisticated simulations, we strongly recommend using PedigreeSim V2.0
https://github.com/PBR/pedigreeSim
an object of class mappoly.data
. See
read_geno
for more information
Marcelo Mollinari, mmollin@ncsu.edu
Mollinari, M., and Garcia, A. A. F. (2019) Linkage analysis and haplotype phasing in experimental autopolyploid populations with high ploidy level using hidden Markov models, _G3: Genes, Genomes, Genetics_. doi: 10.1534/g3.119.400378
h.temp <- sim_homologous(ploidy = 6, n.mrk = 20, max.d = 3, max.ph = 3, seed = 123) fake.poly.dat <- poly_cross_simulate(ploidy = 6, rf.vec = .05, n.mrk = 20, n.ind = 200, h.temp, seed = 123) plot(fake.poly.dat)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.