Learn R Programming

Signac (version 1.6.0)

BigwigTrack: Plot data from BigWig

Description

Create a BigWig track. Note that this function does not work on windows.

Usage

BigwigTrack(
  region,
  bigwig,
  smooth = 200,
  type = "coverage",
  y_label = "bigWig",
  bigwig.scale = "common",
  ymax = NULL,
  max.downsample = 3000,
  downsample.rate = 0.1
)

Arguments

region

GRanges object specifying region to plot

bigwig

Path to a bigwig file

smooth

Number of bases to smooth data over (rolling mean). If NULL, do not apply smoothing.

type

Plot type. Can be one of "line", "heatmap", or "coverage"

y_label

Y-axis label

bigwig.scale

Scaling to apply to data from different bigwig files. Can be:

  • common: plot each bigwig on a common scale (default)

  • separate: plot each bigwig on a separate scale ranging from zero to the maximum value for that bigwig file within the plotted region

ymax

Maximum value for Y axis. Can be one of:

  • NULL: set to the highest value among all the tracks (default)

  • qXX: clip the maximum value to the XX quantile (for example, q95 will set the maximum value to 95% of the maximum value in the data). This can help remove the effect of extreme values that may otherwise distort the scale.

  • numeric: manually define a Y-axis limit

max.downsample

Minimum number of positions kept when downsampling. Downsampling rate is adaptive to the window size, but this parameter will set the minimum possible number of positions to include so that plots do not become too sparse when the window size is small.

downsample.rate

Fraction of positions to retain when downsampling. Retaining more positions can give a higher-resolution plot but can make the number of points large, resulting in larger file sizes when saving the plot and a longer period of time needed to draw the plot.