plotCoverage: Plot read coverage and splice junction read counts

Description Usage Arguments Value Author(s) Examples

View source: R/plots.R

Description

Plot read coverage and splice junction read counts for an individual sample or averaged across samples.

Usage

1
2
3
4
5
plotCoverage(x, geneID = NULL, geneName = NULL, eventID = NULL,
  which = NULL, sample_info = NULL, sizefactor = NA, toscale = c("exon",
  "none", "gene"), color = "darkblue", ylim = NULL, label = NULL,
  nbin = 200, summary = mean, curvature = 1, main = NULL,
  min_anchor = 1, cores = 1)

Arguments

x

SGFeatureCounts or SGFeatures object. If x is an SGFeatureCounts object that includes multiple samples, average coverage and splice junction counts are obtained.

geneID

Single gene identifier used to subset x

geneName

Single gene name used to subset x

eventID

Single event identifier used to subset x

which

GRanges used to subset x

sample_info

Data frame with sample information. If x is an SGFeatureCounts object, sample information is obtained from colData(x). If sample_info includes multiple samples, average coverage and splice junction counts are obtained.

sizefactor

Numeric vector with length equal to the number of samples in sample_info. Used to scale coverages and splice junction counts before plotting, or before averaging across samples. Set to NA to disable scaling. If NULL, size factors are calculated as the number of bases sequenced (the product of library size and average number of bases sequenced per read or fragment), plotted coverages and splice junction counts are per 1 billion sequenced bases.

toscale

Controls which parts of the splice graph are drawn to scale. Possible values are “none” (exonic and intronic regions have constant length), “exon” (exonic regions are drawn to scale) and “gene” (both exonic and intronic regions are drawn to scale).

color

Color used for plotting coverages

ylim

Numeric vector of length two, determining y-axis range used for plotting coverages.

label

Optional y-axis label

nbin

Number of bins for plotting coverages

summary

Function used to calculate per-bin coverage summaries

curvature

Numeric determining curvature of plotted splice junctions.

main

Plot title

min_anchor

Integer specifiying minimum anchor length

cores

Number of cores available for parallel processing.

Value

data.frame with information on splice junctions included in the splice graph

Author(s)

Leonard Goldstein

Examples

1
2
3
4
5
6
## Not run: 
par(mfrow = c(4, 1))
for (j in seq_len(4)) plotCoverage(sgfc_pred[, j])

## End(Not run)
NULL

ldg21/SGSeq documentation built on Oct. 14, 2020, 9:51 p.m.