smooth.region.plot {MVisAGe} | R Documentation |
A Function for Plotting Smoothed Pearson Correlation Coefficients Genomewide
Description
This function plots smoothed R or R^2 values produced by corr.list.compute() genomewide.
Usage
smooth.region.plot(plot.list, plot.chr, plot.start, plot.stop,
plot.column = "R^2", annot.colors = c("black", "red", "green", "blue",
"cyan"), vert.pad = 0.05, ylim.low = NULL, ylim.high = NULL,
plot.legend = TRUE, legend.loc = "topleft", lty.vec = NULL,
lwd.vec = NULL, loess.span = 50, expand.size = 50,
xaxis.label = "Position (Mb)", yaxis.label = NULL, main.label = NULL,
axis.cex = 1, label.cex = 1, xaxis.line = 1.5, yaxis.line = 2.5,
main.line = 0)
Arguments
plot.list |
A list produced by corr.list.compute(). |
plot.chr |
The chromosome for which gene-level R or R^2 values will be plotted. |
plot.start |
The genomic position (in base pairs) where the plot will start. |
plot.stop |
The genomic position (in base pairs) where the plot will stop. |
plot.column |
"R" or "R^2" depending on whether Pearson correlation coefficients or squared Pearson correlation coefficients will be plotted. Default = "R^2". |
annot.colors |
A vector of colors used for plotting values in different entries of plot.list. Default = c("black", "red", "green", "blue", "cyan"). |
vert.pad |
Amount of vertical white space in the plot. Default = 0. |
ylim.low |
Smallest value on the y-axis (used to control the range of values on the y-axis). Default = NULL. |
ylim.high |
Largest value on the y-axis (used to control the range of values on the y-axis). Default = NULL. |
plot.legend |
Logical value specifying whether a legend should be included. Default = FALSE. |
legend.loc |
Character value specifing the location of the legend. Default = "topright". See See |
lty.vec |
Vector specifying line types for plotting values in different entries of plot.list. Default = NULL. See |
lwd.vec |
Vector specifying line widths for plotting values in different entries of plot.list. Default = NULL. See |
loess.span |
A numerical value used to control the level of smoothing. Smoothing is performed separately for each chromosome, and loess.span effectively defines the number of genes in each smoothing window. Default = 250. |
expand.size |
A numerical value used to control smoothing at the ends of the region of interest. Both ends of the region are artificially extended by expand.size genes, smoothing is performed on the expanded region, and then the smoothed values are restricted to the size of the original region. Default = 50. |
xaxis.label |
Text used to label the x-axis of the plot. Default = "Chromosome". See |
yaxis.label |
Text used to label the y-axis of the plot. Default = NULL. See |
main.label |
Text used to label the plot header. Default = NULL. See |
axis.cex |
Numerical value used to specify the font size on the axes. Default = 1. See |
label.cex |
Numerical value used to specify the font size for the axis labels. Default = 1. See |
xaxis.line |
Numerical value used to specify location of xaxis.label. Default = 0. See |
yaxis.line |
Numerical value used to specify location of yaxis.label. Default = 0. See |
main.line |
Numerical value used to specify location of main.label. Default = 0. See |
Value
Creates a plot of gene-level R or R^2 values produced by corr.list.compute().
Examples
exp.mat = tcga.exp.convert(exp.mat)
cn.mat = tcga.cn.convert(cn.mat)
prepped.data = data.prep(exp.mat, cn.mat, gene.annot, sample.annot, log.exp = FALSE)
pd.exp = prepped.data[["exp"]]
pd.cn = prepped.data[["cn"]]
pd.ga = prepped.data[["gene.annot"]]
pd.sa = prepped.data[["sample.annot"]]
output.list = corr.list.compute(pd.exp, pd.cn, pd.ga, pd.sa)
smooth.region.plot(plot.list = output.list, plot.chr = 11, plot.start = 0e6, plot.stop = 135e6)