annotationCoverageAroundFeatures: Extract stranded annotation profiles at and around a set of...

Description Usage Arguments Value DETAILS Author(s) See Also Examples

View source: R/annotationCoverageAroundFeatures.R

Description

Extract stranded annotation profiles at and around a set of features/intervals.

Usage

1
2
3
4
5
6
7
8
annotationCoverageAroundFeatures(
  annot,
  features = NULL,
  sidedist = 2000L,
  usePercent = FALSE,
  BinFeatures = TRUE,
  ...
)

Arguments

annot

A GRanges of (stranded) genomic annotations

features

An optional GRanges or a character vector with a subset of annot names to extract profiles at. Defaults to NULL for all annot features.

sidedist

Integer. Distance on each side of features at which to extract the profiles

usePercent

Logical. Should annotation coverage be expressed as presence/absence (0/1)? (instead of counting the number of features aligning at each position)

BinFeatures

Logical. Should features be binned? Default to TRUE and will be forced to TRUE if features have different width.

...

additional arguments passed to binFeatureProfiles

Value

A list with the following elements:

DETAILS

The usePercent option is intended to give a percentage of bases covered by annotations when performing average profiles from several features.
When calculating a coverage with usePercent=TRUE any value > 1 is replaced by 1.
This is equivalent to calculating coverage(reduce(annot)) instead of coverage(annot).

Author(s)

Pascal GP Martin

See Also

binFeatureProfiles

Examples

1
2
## Extract the profiles around (+/-50bp) all genes. We bin the genes in 3 bins only.
AllProf <- annotationCoverageAroundFeatures(Genegr, sidedist = 50, usePercent = TRUE, nbins=3)

pgpmartin/GeneNeighborhood documentation built on Sept. 2, 2021, 6:37 a.m.