Learn R Programming

AlphaSimR (version 1.6.0)

getGenMap: Get genetic map

Description

Retrieves the genetic map for all loci.

Usage

getGenMap(object = NULL, sex = "A")

Value

Returns a data.frame with:

id

Unique identifier for locus

chr

Chromosome containing the locus

pos

Genetic map position

Arguments

object

where to retrieve the genetic map. Can be an object of SimParam or MapPop-class. If NULL, the function will look for a SimParam object called "SP" in your global environment.

sex

determines which sex specific map is returned. Options are "A" for average map, "F" for female map, and "M" for male map. All options are equivalent if not using sex specific maps or using pulling from a MapPop.

Examples

Run this code
#Create founder haplotypes
founderPop = quickHaplo(nInd=10, nChr=1, segSites=10)

#Set simulation parameters
getGenMap(founderPop)

Run the code above in your browser using DataLab