getPosition: Obtain marker positions

getPositionR Documentation

Obtain marker positions

Description

This function returns physical positions of markers.

Usage

getPosition(object, valid = TRUE, chr = NULL, ...)

## S4 method for signature 'GbsrGenotypeData'
getPosition(object, valid, chr)

Arguments

object

A GbsrGenotypeData object.

valid

A logical value. See details.

chr

A integer or string to specify chromosome to get information.

...

Unused.

Details

If valid = TRUE, the positions of the markers which are labeled TRUE in the "valid" column of the "marker" slot will be returned. If you need the positions of over all markers, set valid = FALSE. validMar() tells you which markers are valid.

Value

An integer vector indicating the physical positions of markers.

Examples

# Load data in the GDS file and instantiate a [GbsrGenotypeData] object.
gds_fn <- system.file("extdata", "sample.gds", package = "GBScleanR")
gds <- loadGDS(gds_fn)

getPosition(gds)

# Close the connection to the GDS file.
closeGDS(gds)


tomoyukif/GBScleanR documentation built on Oct. 31, 2024, 2:43 a.m.