Description Usage Arguments Details Value Note Author(s) References See Also Examples
A generic function to recombine two haploid parental genomes (as found in sex cell) into one haploid progeny genome (i.e. the gamete)
1 2 3 4 | hypredRecombine(object, ...)
## S4 method for signature 'hypredGenome'
hypredRecombine(object, genomeA, genomeB,
mutate, mutation.rate.snp, mutation.rate.qtl, block)
|
object |
an object of a class that holds information on genome
parameters necessary to simulate meiosis, typically an
|
genomeA |
One of the haploid parental genomes. An integer vector or one row matrix. The two SNP alleles are coded as 1 and 0. |
genomeB |
The other of the haploid parental genomes. An integer vector or one row matrix. The two SNP alleles are coded as 1 and 0. |
mutate |
Logical argument indicating if mutations should be simulated as well,
|
mutation.rate.snp |
The mutation rate of SNP μ (per base pair), a numeric
value. If |
mutation.rate.qtl |
The mutation rate of QTL μ (per base pair), a numeric
value. If |
block |
logical argument indicating if the map positions of the
SNP themselfes should be used ( |
... |
Methods may require further arguments. |
The meiosis is simulated according to the count-location model that assumes no interference. Here the number of crossing over on a random meiotic product of a chromosome is Poission distributed with parameter λ = L (L being the length of the chromosome in Morgan). The location of the crossing over follow a uniform distribution over the interval (0,L).
The computations for simulating the meiosis are performed by a
routine written in C and called through .C
.
Since the count-location model corresponds to the Haldane mapping function, observed recombination frequencies between loci must agree with the expected ones as calculated from the inverse of the Haldane function from the map distances. This fact was used to validate the algorithm. If you want to do this yourself, remember to use a sufficently high number of progenies.
The occurence of mutations is simulated according to a simple
count-location model as well. The number of observed SNP mutations in
the gamete follows a Poission distribution with parameter
λ = μ times the number of SNP (i.e. loci not
assigned QTL) on a chromosome times the number of chromosomes
(mutation.rate.snp * object@num.snp.chr *
object@num.chr
). Then each SNP-loci has an equal chance of beeing
mutated, irrespective on whether mutations occured in its vicinity. A
mutation event always changes a 1 allele to a 0 allele and vice versa
(i.e. 0 to 1; 1 to 0). During one meiosis, a given SNP-loci can only
be mutated twice if the number of mutations exceeds the total number
of SNP. This should rarely happen and is included only to avoid an
error. The same applies to mutations of QTL.
Since all the simulated loci are treated as SNP, μ should be interpreted as μ per base-pair per meiosis.
A one row matrix with ncol(genomeA)
resp. ncol(genomeB)
columns, giving the genotype of the gamete. The two SNP alleles are coded as 1 and 0.
The function call the C routine meiosisFUNallChr
to
simulate the meiosis.
Frank Technow
Wu, R.; Chang-Xing, M; Casella, G.; (2007) Statistical Genetics of Quantitative Traits. New York: Springer.
The function hypredGenome
which creates the
"hypredGenome"
object, and the function
hypredFounder
which creates genomes of founder lines
from which progenies can be created by function hypredRecombine
.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 | ## one chromosome of length 1 M and 5 SNP
genomeDef <- hypredGenome(1, 1.0, 5)
## produce two haploid founder line genomes
founder <- hypredFounder(genomeDef,1)
founder
## produce one gamete from a cross between the two
set.seed(135)
gamete <- hypredRecombine(genomeDef,
genomeA = founder[1,],
genomeB = founder[2,],
mutate = FALSE,
block = FALSE)
print(gamete)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.