pedisimu {KINSIMU} | R Documentation |
Pedigree simulation
Description
Generating genotype combinations of multiple pedigrees with specific relationships on an autosomal marker.
Usage
pedisimu(
af,
ss,
pedi,
random_name = "RI",
muf = 0,
mum = 0,
allelename = FALSE
)
Arguments
af |
name of allele frequency matrix, a data.frame of 1 column containing frequencies with allele names being row names, which can be loaded with "EvaluatePanel" function, not necessary if Parent is not NULL |
ss |
sample size, i.e., how many individual pairs do you want simulate |
pedi |
a matrix in data.frame form containing the pedigree structure information |
random_name |
the name of random individual, with a default of "RI" |
muf |
father-child mutation rate |
mum |
mother-child mutation rate |
allelename |
if TRUE the output data would be the allele name, which should be the row names of af matrix, otherwise, it would be the position in that matrix |
Value
A data.frame with ss
rows and 2*n
columns, where n
is equal to the number of rows in the pedi data.frame. Each pair of columns contains alleles of an individual, with the individuals sorted in the same order as in the pedi data.frame.
Examples
#simulating a first cousin pedigree without considring mutation
pedi<-pediexample
af<-FortytwoSTR$afmatrix[[1]]
pedisimu(af = af,ss = 10000,pedi = pedi)