calculateCoverageProfile: calculateCoverageProfile

Description Usage Arguments Value Examples

Description

This function checks overlaps between input query regions and annotation features, and then calculates coverage profile along target regions.

Usage

1
2
3
4
5
6
7
8
calculateCoverageProfile(
  queryRegions,
  targetRegions,
  sampleN = 0,
  bin.num = 100,
  bin.op = "mean",
  strand.aware = TRUE
)

Arguments

queryRegions

GRanges object imported from a BED file using importBed function

targetRegions

GRanges object containing genomic coordinates of a target feature (e.g. exons)

sampleN

If set to a positive integer, targetRegions will be downsampled to sampleN regions

bin.num

Positive integer value (default: 100) to determine how many bins the targetRegions should be split into (See genomation::ScoreMatrixBin)

bin.op

The operation to apply for each bin: 'min', 'max', or 'mean' (default: mean). (See genomation::ScoreMatrixBin)

strand.aware

TRUE/FALSE (default: TRUE) The strands of target regions are considered.

Value

A ScoreMatrix object returned by genomation::ScoreMatrixBin function. Target regions are divided into 100 equal sized bins and coverage level is calculated in a strand-specific manner.

Examples

1
2
3
4
5
6
data(gff)
data(queryRegions)
txdbFeatures <- getTxdbFeaturesFromGRanges(gffData = gff)
df <- calculateCoverageProfile(queryRegions = queryRegions,
                              targetRegions = txdbFeatures$exons,
                                    sampleN = 1000)

RCAS documentation built on April 29, 2020, 5:38 a.m.