Learn R Programming

derfinder (version 1.6.4)

coerceGR: Coerce the coverage to a GRanges object for a given sample

Description

Given the output of fullCoverage, coerce the coverage to a GRanges object.

Usage

coerceGR(sample, fullCov, ...)

Arguments

sample
The name or integer index of the sample of interest to coerce to a GRanges object.
fullCov
A list where each element is the result from loadCoverage used with returnCoverage = TRUE. Can be generated using fullCoverage.
...
Arguments passed to other methods and/or advanced arguments.

Value

  • A GRanges object with score metadata vector containing the coverage information for the specified sample. The ranges reported are only those for regions of the genome with coverage greater than zero.

See Also

GRanges

Examples

Run this code
## Create a small fullCov object with data only for chr21
fullCov <- list('chr21' = genomeDataRaw)

## Coerce to a GRanges the first sample
gr <- createBwSample('ERR009101', fullCov = fullCov,
    seqlengths = c('chr21' = 48129895))

## Explore the output
gr

Run the code above in your browser using DataLab