Description Usage Arguments Value Implementation Examples
Plots distributions for each combination of FUNS, channels and sampleColors. By default, samples are ordered according to the sampleColors (if provided). Colors should be provided as factors with a preset order of levels; the order of colors is determined by the order of levels
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 |
RGList |
A list of matrices of signal intensities per channel |
filePath |
NULL or character; if given, output a PDF; default NULL |
channels |
List of data.frames from RGList, e.g. list("log2(R)", "log2(G)") |
FUNS |
geom_functions from ggplot2, default |
probeTypeVec |
Vector of probe types |
probeTypeValue |
Value from probeTypeVec to use for plotting |
numProbes |
Number of randomly select probes |
sampleColors |
Tibble of named factors of colors with names matching sample names |
orderByColors |
Logical for ordering samples by colors (coded as a factor with levels in order); default TRUE |
scale_x_limits |
NULL for auto-scale; use c(0,16) or less for log2(intensities) |
width |
PDF width, default 16/9*7=12.44 |
height |
PDF height, default 7 |
... |
Passed to ggplot2::FUN, e.g.: bins, binwidth, show.legend |
A list of ggplots, one per a combination of FUNS, channels and sampleColors PDF if filePath is not NULL
See https://www.tidyverse.org/blog/2020/02/glue-strings-and-tidy-eval/ for bracing variables.
Evaluation of expression: https://adv-r.hadley.nz/evaluation.html.
For bquote(a +. (b))
: http://adv-r.had.co.nz/Expressions.html.
1 2 3 4 5 6 7 8 9 10 11 | ## Not run:
plotDistr_RGList(dataRG.bgc, file.path(curDir, "density-boxplot_dataRG.bgc_genes.pdf"),
channels = c("log2R","log2G","beta"), probeTypeVec = dataRG.bgc$genes$ControlType, probeTypeValue = 0,
numProbes = 10000, sampleColors = targets %>% select(starts_with("color_")))
## Removed parameters/code:
# transform = log2: transformation function applied to each channel (default: log2; identity for none)
mutate("{{transform}}({ch})" := transform(!!parse_expr(ch)))
ggplot(aes(x=transform(!!parse_expr(ch)), color=HybName)) +
ggplot(d2, aes(x=!!parse_expr(ch), color=fct_reorder(HybName, order(colors)))) + #, order=colors)) +
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.