Description Usage Arguments Value Note Examples
Define a shiny app for comparing projections
1 2 | pcmpApp(sce, assayind = 1, cellIdTag = ".cellid",
selectionPrefix = "sel_", numDiscGenes = 20)
|
sce |
SingleCellExperiment instance with reducedDims populated with various candidates for projection from assay data – |
assayind |
numeric(1) 'i' argument to assay(sce, i), defaults to 1, for extracting expression values |
cellIdTag |
character(1) defaulting to ".cellid", added to colData(sce) for tracking selections |
selectionPrefix |
character(1) defaulting to "sel_", prefix for the name of a selection indicator variable added to colData(sce) |
numDiscGenes |
numeric(1) used to limit number of differentially expressed genes tabulated per selection |
will return an updated SingleCellExperiment
In sce300xx, names(reducedDims) are 'PPCA', 'UMAP*', 'TSNE*' for projections generated by irlba::irlba, umap::umap, and Rtsne::Rtsne respectively. Prior to pcmp version 0.4.0, the projections were computed and prepared differently. As Rtsne no longer allows dims > 3, we have separately computed and stored t-SNE projections into 2- and 3- dimensional spaces, labeled TSNE2 and TSNE3. (In previous versions of pcmp, the 4-d t-SNE was computed and marginal planar projections were provided.) Note that tabulation of DE genes can be very slow if the input SingleCellExperiment has more than 10k rows.
1 2 3 4 5 6 7 8 9 10 11 12 | if (interactive()) {
message("be sure to use example(pcmpApp, ask=FALSE)")
lit = pcmp::sce300xx
sds = rowSds(assay(lit))
top1k = order(sds,decreasing=TRUE)[1:1000]
lit = lit[top1k,]
chk = pcmpApp(lit) # fires up browser, if ask != FALSE you must
# assent to each update
try(chk) # may error if no selections
try(head(metadata(chk)$limmaTabs,3)) # likewise
try(table(metadata(chk)$limmaTabs$featid)) # likewise
}
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.