Learn R Programming

Chicago (version 1.0.3)

plotBaits: Plot Baits

Description

Plot the read counts around baits.

Usage

plotBaits(cd, pcol = "score", Ncol = "N", n = 16, baits = NULL, plotBaitNames = TRUE, plotBprof = FALSE, plevel1 = 5, plevel2 = 3, outfile = NULL, removeBait2bait = TRUE, width = 20, height = 20, maxD = 1e6, bgCol = "black", lev2Col = "blue", lev1Col = "red", bgPch = 1, lev1Pch = 20, lev2Pch = 20, ...)

Arguments

cd
A chicagoData object.
pcol
The name of the column that contains the score.
Ncol
The name of the column that contains counts.
n
The number of baits to plot (ignored if baits is specified).
baits
The IDs of the baits to plot.
plotBaitNames
If TRUE, the names of the baits, rather than their IDs, will appear in the plot.
plotBprof
If TRUE, display a line representing the expected Brownian noise at each distance.
plevel1, plevel2
Thresholds used on the pcol column. plevel1 should be the more stringent threshold.
outfile
If NULL, output to current plotting device. Otherwise, this specifies a pdf file to write to.
removeBait2bait
If TRUE, bait-to-bait interactions are not plotted.
width, height
Passed through to pdf
maxD
The maximum (linear) distance each side of the bait to plot (NULL to include the whole chromosome).
bgCol, lev1Col, lev2Col
Colours to be used for background points, and for the two stringency levels defined by plevel1 and plevel2, respectively.
bgPch, lev1Pch, lev2Pch
Plotting character for background points, and for points exceeding the two stringency levels defined by plevel1 and plevel2, respectively. Specified as per pch in points.
...
Additional arguments passed to plot

Value

Vector of the baitIDs plotted (useful if baitIDs were sampled randomly).

Examples

Run this code
data(cdUnitTest)

##modifications to cdUnitTest, ensuring it uses correct design directory
designDir <- file.path(system.file("extdata", package="Chicago"), "unitTestDesign")
cdUnitTest <- modifySettings(cd=cdUnitTest, designDir=designDir)

plotBaits(cdUnitTest)

Run the code above in your browser using DataLab