Learn R Programming

ibdsim2 (version 2.2.0)

maplengths: Physical and genetic map lengths

Description

Utility functions for extracting the physical or genetic length of chromosome maps and genome maps.

Usage

mapLen(x, ...)

# S3 method for chromMap mapLen(x, sex = c("male", "female"), ...)

# S3 method for genomeMap mapLen(x, sex = c("male", "female"), ...)

physRange(x, ...)

# S3 method for chromMap physRange(x, ...)

# S3 method for genomeMap physRange(x, ...)

Value

mapLen() returns a numeric of the same length as sex, with the genetic length(s) in centiMorgan.

physRange() returns the physical length (in Mb) of the chromosome/genome covered by the map. For example, for a chromosome map starting at 2 Mb and ending at 8 Mb, the output is 6.

Arguments

x

A chromMap or genomeMap object.

...

Not used.

sex

Either "male", "female" or both.

See Also

loadMap(), uniformMap()

Examples

Run this code
m = loadMap(chrom = 1:2)
m

# Applied to `genomeMap` object:
physRange(m)
mapLen(m)

# Applied to `chromMap` object:
physRange(m[[1]])
mapLen(m[[1]])

Run the code above in your browser using DataLab