getCountReadRef: Obtain total reference read counts per SNP or per sample

getCountReadRefR Documentation

Obtain total reference read counts per SNP or per sample

Description

Obtain total reference read counts per SNP or per sample

Usage

getCountReadRef(object, target = "marker", valid = TRUE, prop = FALSE, ...)

## S4 method for signature 'GbsrGenotypeData'
getCountReadRef(object, target, valid, prop)

Arguments

object

A GbsrGenotypeData object.

target

Either of "marker" and "sample".

valid

A logical value. See details.

prop

A logical value whether to return values as proportions of total reference read counts in total read counts per SNP or not.

...

Unused.

Details

You need to execute countRead() to calculate sumaary statisticsto be obtained via this function. If valid = TRUE, the chromosome information of markers which are labeled TRUE in the sample slot will be returned. validMar() tells you which samples are valid.

Value

A numeric vector of (proportion of) reference read counts per marker.

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)
gds <- countRead(gds)

getCountReadRef(gds)

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


tomoyukif/GBScleanR documentation built on May 7, 2024, 6:53 p.m.