ShinyCell2
ShinyCell2 is a lightweight R package for building interactive, shareable apps to explore single-cell multi-omics, scATAC-seq and spatial transcriptomics data with customizable, publication-ready visualizations.
Install / Use
/learn @the-ouyang-lab/ShinyCell2README
ShinyCell2
ShinyCell2 is an enhanced R package for creating interactive, lightweight,
and shareable web applications to explore single-cell multi-omics and spatial
transcriptomics data. Building on the simplicity of the original ShinyCell,
ShinyCell2 introduces powerful new features tailored for modern single-cell
modalities, including support for CITE-seq, scATAC-seq, and spatial
transcriptomics. It integrates seamlessly with popular analysis tools like
Seurat, Scanpy, Signac, and ArchR, and offers advanced visualizations such as
zoom-enabled UMAPs, IGV-style peak tracks, and spatial plots—all easily
customizable and deployable with minimal dependencies. Designed for both
computational and experimental researchers, ShinyCell2 empowers intuitive
exploration, cross-modality comparison, and statistical analysis of
high-dimensional data without requiring extensive coding or setup. An example
web app showcasing the visualization of spatial transcriptomics, scATAC-seq,
and CITE-seq datasets can be accessed at https://shinycell.ouyanglab.com/
If you are using ShinyCell2, please cite the biorxiv preprint.
The manuscript is currently under review.
Key features of ShinyCell2 include:
-
Supports seamless integration and visualization of single-cell multi-omics, peak-based, and spatial data for in-depth exploration.
-
Converts data from leading analysis tools—including Scanpy, Seurat, Signac, and ArchR—into a lightweight, portable format suitable for local or web-based deployment, enabling open and accessible data sharing.
-
Offers a rich collection of interactive, customizable, and publication-ready plots.
-
Easily extendable, with support for user-defined visualizations through R for tailored analysis workflows.
We also compared ShinyCell2 with other popular single cell data visualisation
tools, which further highlights the key features of ShinyCell2.
| Feature | cellxgene | Vitessce | WebAtlas | ShinyCell2 | |:---------------------------|:---------------------------------------:|:-------------------------------------:|:-------------------------------------:|:-------------------------------------:| | Framework | JavaScript/Python/R | JavaScript/Python/R | Vitessce-based | R/Shiny | | Spatial data support | <span style="color:red;">limited</span> | <span style="color:green;">yes</span> | <span style="color:green;">yes</span> | <span style="color:green;">yes</span> | | Multi-omics integration | <span style="color:red;">limited</span> | <span style="color:green;">yes</span> | <span style="color:green;">yes</span> | <span style="color:green;">yes</span> | | Cross-model queries | <span style="color:red;">limited</span> | <span style="color:green;">yes</span> | <span style="color:green;">yes</span> | <span style="color:green;">yes</span> | | Configuration Complexity | low, via command line | high, via multiple joson files | low, via parameter file | low, via config object | | Customisation | limited | extensive but req. expertise | limited | extensive and user-friendly | | R/Bioconductor Integration | via cellxgenedp package | via vitessceR package | <span style="color:red;">no</span> | <span style="color:green;">full</span> | | Deployment | primarily web-based | primarily web-based | primarily web-based | local and web-based | | Local Deployment | yes via R | local http server | local http server | yes, via Rstudio / Rstudio server |
Table of Contents and Additional Information / Tutorials
This readme is broken down into the following sections:
-
Installation on how to install
ShinyCell2 -
Quick Start Guide to rapidly deploy a shiny app with a few lines of code
There are also additional information / tutorials as follows:
-
Additional information on new visualisations tailored for spatial / scATAC-seq / multiomics
-
Tutorial for creating a ShinyCell2 app for scRNA-seq or CITE-seq data
-
Tutorial for creating a ShinyCell2 app for ArchR-based scATAC-seq data
-
Tutorial for creating a ShinyCell2 app for Signac-based scATAC-seq data
-
Tutorial for creating a ShinyCell app containing several datasets
Installation
First, users can run the following code to check if the packages required by
ShinyCell2 exist and install them if required:
reqPkg = c("data.table", "Matrix", "hdf5r", "reticulate", "R.utils",
"ggplot2", "gridExtra", "glue", "readr", "future", "RColorBrewer")
newPkg = reqPkg[!(reqPkg %in% installed.packages()[,"Package"])]
if(length(newPkg)){install.packages(newPkg)}
# If you are using Seurat object as input (for scRNA, multiomics, spatial),
# you can install Seurat as follows:
# install.packages("Seurat")
# If you are using Signac object for scATAC-seq, you can install Signac as follows:
# install.packages("Signac")
# If you are using ArchR object as input for scATAC-seq, visit
# https://github.com/GreenleafLab/ArchR for ArchR's installation instruction
# If you are using h5ad file as input, run code below
# reticulate::py_install("anndata")
Furthermore, on the system where the Shiny app will be deployed, users can run the following code to check if the packages required by the Shiny app exist and install them if required:
reqPkg = c("shiny", "shinyhelper", "data.table", "Matrix", "DT", "magrittr",
"ggplot2", "ggrepel", "hdf5r", "ggdendro", "gridExtra", "ggpubr")
newPkg = reqPkg[!(reqPkg %in% installed.packages()[,"Package"])]
if(length(newPkg)){install.packages(newPkg)}
If one is deploying scATAC-seq / peak-based data, bwtools have to be installed for the track plots via the command line:
# Install dependencies for trackplot (on command line)
git clone https://github.com/CRG-Barcelona/libbeato.git
cd ./libbeato
git checkout 0c30432
./configure
make
make install
cd ..
git clone https://github.com/CRG-Barcelona/bwtool.git
cd ./bwtool
./configure
make
make check
make install
ShinyCell2 can then be installed from GitHub as follows:
devtools::install_github("the-ouyang-lab/ShinyCell2")
Quick Start Guide
In short, the ShinyCell2 package takes in an input single-cell object and
generates a ShinyCell2 config scConf containing labelling and colour palette
information for the single-cell metadata. The ShinyCell config and single-cell
object are then used to generate the files and code required for the shiny app.
In this example, we will use single-cell CITE-seq data in the form of a Seurat object containing 162,000 PBMC cells measured with 228 antibodies, taken from https://satijalab.org/seurat/articles/multimodal_reference_mapping.html The Seurat object can be downloaded here.
A shiny app can be readily generated using the following code:
library(Seurat)
library(ShinyCell2)
seu <- readRDS("multimodal_pbmc.rds")
scConf <- createConfig(seu)
makeShinyFiles(seu,scConf, shiny.prefix="sc1", shiny.dir="shinyApp/")
makeShinyCodes(shiny.title = "PBMC multiomics", shiny.prefix="sc1",
shiny.dir="shinyApp/")
The generated shiny app can then be found in the shinyApp/ folder (which is
the default output folder). To run the app locally, use RStudio to open either
server.R or ui.R in the shiny app folder and click on "Run App" in the top
right corner. The shiny app can also be deployed online via online platforms
e.g. shinyapps.io and Amazon Web Services (AWS)
or be hosted via Shiny Server. For further details, refer to
Instructions on how to deploy ShinyCell apps online.
More details on the various visualisations in the ShinyCell2 can be found in
[Additional information on new visualisations tailored for spatial / scATAC-seq / multiomics](
https://htmlpreview.github.io/?https://github.com/the-ouyang-lab/ShinyCe
Related Skills
node-connect
342.5kDiagnose OpenClaw node connection and pairing failures for Android, iOS, and macOS companion apps
frontend-design
85.3kCreate distinctive, production-grade frontend interfaces with high design quality. Use this skill when the user asks to build web components, pages, or applications. Generates creative, polished code that avoids generic AI aesthetics.
openai-whisper-api
342.5kTranscribe audio via OpenAI Audio Transcriptions API (Whisper).
qqbot-media
342.5kQQBot 富媒体收发能力。使用 <qqmedia> 标签,系统根据文件扩展名自动识别类型(图片/语音/视频/文件)。
