plotBinCounts
visualizes the raw read counts (i.e., before binning user regions) across regions or a user-defined genomic range.
Note that only the results of a particular chromosome can be visualized. It is therefore only possible if the regions to be visualized
are located on one particular chromosome; otherwise, an error is thrown.
plotRegionCounts(SNPhood.o, regions = NULL, datasets = NULL, readGroups = NULL, mergeReadGroupCounts = FALSE, plotChr = NULL, plotStartPos = NULL, plotEndPos = NULL, ylim = NULL, plotRegionBoundaries = FALSE, plotRegionLabels = FALSE, maxWidthLabels = NULL, colorPalette = "Set1", sizePoints = 4, type = "p", plotGraph = TRUE, fileToPlot = NULL, verbose = FALSE)
SNPhood
annotationRegions
). If set to NULL, all regions will be considered.annotationDatasets
). If set to NULL, all datasets will be considered.annotationReadGroups
). If set to NULL, all read groups will be considered.regions
) determine which genomic region should be plotted.plotChr
is not NULL, the start coordinates are set to 1.plotChr
is not NULL, the end coordinates are determined automatically and the full chromosome will be plotted.RColorBrewer
package from the qualitative palettes
for the colors of the datasets that are plotted.
Allowed palette names are "Accent", "Dark2", "Paired", "Pastel1", "Pastel2", "Set1", "Set2", and "Set3". Colors for the datasets are
then determined automatically from the given palette name (from left to right, depending on the number of datasets to be plotted).
The colors for the read groups within each datasets are based on the colors for the dataset, but with different saturation values.NULL
. Default NULL
.
Filename of the PDF file for the output plots.
If set to NULL
, plots will be plotted to the currently active device.data(SNPhood.o, package="SNPhood")
# Plot the read counts for the first ten regions
plot = plotRegionCounts(SNPhood.o, regions = 1:10)
# Plot the read counts for the full chr21
plot = plotRegionCounts(SNPhood.o, plotChr = "chr21")
# Plot the read counts for the full chr21, merge read group counts and decrease the point size
plot = plotRegionCounts(SNPhood.o, plotChr = "chr21", sizePoints = 2, mergeReadGroupCounts = TRUE)
Run the code above in your browser using DataLab