Learn R Programming

derfinder (version 1.6.4)

annotateRegions: Assign genomic states to regions

Description

This function takes the regions found in calculatePvalues and assigns them genomic states contructed with makeGenomicState. The main workhorse functions are countOverlaps and findOverlaps.

Usage

annotateRegions(regions, genomicState, annotate = TRUE, ...)

Arguments

regions
The $regions output from calculatePvalues.
genomicState
A GRanges object created with makeGenomicState. It can be either the genomicState$fullGenome or genomicState$codingGenome component.
annotate
If TRUE then the regions are annotated by the genomic state. Otherwise, only the overlaps between the regions and the genomic states are computed.
...
Arguments passed to other methods and/or advanced arguments.

Value

  • A list with elements countTable and annotationList (only if annotate=TRUE). [object Object],[object Object]

Details

You might want to specify arguments such as minoverlap to control how the overlaps are determined. See findOverlaps for further details.

See Also

makeGenomicState, calculatePvalues

Examples

Run this code
## Annotate regions, first two only
annotatedRegions <- annotateRegions(regions=genomeRegions$regions[1:2], 
    genomicState=genomicState$fullGenome, minoverlap=1)
annotatedRegions

Run the code above in your browser using DataLab