Tabulate marker positions
Return a map of the markers attached to a pedigree.
getMap(x, markers = NULL, na.action = 0, verbose = TRUE) setMap(x, map, matchNames = NA, ...)
x |
An object of class |
markers |
A vector of names or indices referring to markers attached to
|
na.action |
Either 0 (default), 1 or 2. (See Details.) |
verbose |
A logical. |
map |
Either a data frame or the path to a map file. |
matchNames |
A logical; if TRUE, pre-existing marker names of |
... |
Further arguments passed to |
The na.action
argument controls how missing values are dealt with:
na.action
= 0: Return map unmodified
na.action
= 1: Replace missing values with dummy values.
na.action
= 2: Remove markers with missing data.
In setMap()
, the map
argument should be a data frame (or file) with the
following columns in order: 1) chromosome, 2) marker name, 3) position in megabases.
Column names are ignored, as are any columns after the first three.
getMap()
returns a data frame with columns CHROM
, MARKER
and
MB
.
setMap()
returns x
with modified marker attributes.
x = singleton(1) m1 = marker(x, chrom = 1, posMb = 10, name = "m1") m2 = marker(x, chrom = 1, posMb = 11) m3 = marker(x, chrom = 1) x = setMarkers(x, list(m1, m2, m3)) # Compare effect of `na.action` getMap(x, na.action = 0) getMap(x, na.action = 1) getMap(x, na.action = 2) # Getting and setting map are inverses y = setMap(x, getMap(x)) identical(x,y)
Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.