Learn R Programming

AlphaSimR (version 0.9.0)

trackHaploPop: Haplotype tracking population

Description

Creates a population contain haplotypes numbered for identity be descent tracking.

Usage

trackHaploPop(genMap, nInd, inbred = FALSE, ploidy = 2L)

Arguments

genMap

a list of genetic maps

nInd

number of individuals

inbred

should individuals be fully inbred

ploidy

ploidy level of organism

Details

Each item of genMap must be a vector of ordered genetic lengths in Morgans. The first value must be zero. The length of the vector determines the number of segregating sites on the chromosome.

If inbred=FALSE, the value of nInd must be less than or equal to 128. Otherwise, it must be less than or equal to 256.

Examples

Run this code
# NOT RUN {
# Create genetic map for a single chromosome with 1 Morgan
# Chromosome contains 11 equally spaced segregating sites
genMap = list(seq(0,1,length.out=11))
founderPop = trackHaploPop(genMap=genMap,nInd=10)

# }

Run the code above in your browser using DataLab