Description Usage Arguments Value Examples
Plot interactive litre plots.
1 2 3 4 5 6 7 8 |
data |
DATA FRAME | Read counts |
dataMetrics |
LIST | Differential expression metrics |
dataSE |
SUMMARIZEDEXPERIMENT | Summarized experiment format that can be used in lieu of data; default NULL |
geneList |
CHARACTER ARRAY | List of gene IDs to be drawn onto the litre. Use this parameter if you have predetermined subset of genes to be drawn. Otherwise, all genes in the data object can be superimposed on the litre plot; default NULL |
pointColor |
CHARACTER STRING | Color of overlaid points on scatterplot matrix; default "orange" |
option |
CHARACTER STRING ["hexagon" | "allPoints"] | The background of plot; default "hexagon"; "allPoints" may be too slow depending on data |
A Shiny application that shows a litre plot background and allows users to superimpose the subset of genes determined to be superimposed through the dataMetrics or geneList parameter. The application allows users to order how to sequentially superimpose the genes by columns in the dataMetrics parameter.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 | # The first pair of examples use data and dataMetrics
# objects as input. The last pair of examples create the same plots now
# using the SummarizedExperiment (i.e. dataSE) object input.
# Example 1: Create an interactive litre plot for the logged data using
# default background of hexagons.
data(soybean_ir_sub)
data(soybean_ir_sub_metrics)
soybean_ir_sub_log <- soybean_ir_sub
soybean_ir_sub_log[,-1] <- log(soybean_ir_sub[,-1]+1)
app <- plotLitreApp(data = soybean_ir_sub_log,
dataMetrics = soybean_ir_sub_metrics)
if (interactive()) {
shiny::runApp(app, port = 1234, launch.browser = TRUE)
}
# Example 2: Repeat the same process, only now plot background data as
# individual points. Note this may be too slow now that all points are drawn
# in the background.
app <- plotLitreApp(data = soybean_ir_sub_log,
dataMetrics = soybean_ir_sub_metrics, option = "allPoints",
pointColor = "red")
if (interactive()) {
shiny::runApp(app)
}
# Below are the same pair of examples, only now using the
# SummarizedExperiment (i.e. dataSE) object as input.
# Example 1: Create an interactive litre plot for the logged data using
# default background of hexagons.
## Not run:
data(se_soybean_ir_sub)
se_soybean_ir_sub_log <- se_soybean_ir_sub
assay(se_soybean_ir_sub_log) <-
log(as.data.frame(assay(se_soybean_ir_sub_log))+1)
app <- plotLitreApp(dataSE = se_soybean_ir_sub_log)
if (interactive()) {
shiny::runApp(app, port = 1234, launch.browser = TRUE)
}
## End(Not run)
# Example 2: Repeat the same process, only now plot background data as
# individual points. Note this may be too slow now that all points are
# drawn in the background.
## Not run:
app <- plotLitreApp(dataSE = se_soybean_ir_sub_log, option = "allPoints",
pointColor = "red")
if (interactive()) {
shiny::runApp(app)
}
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.