本文へ移動
cccskills
無料GitHub で公開

bioconductor-demuxmix

A package for demultiplexing single-cell sequencing experiments of pooled cells labeled with barcode oligonucleotides. The package implements methods to fit regression mixture models for a probabilistic classification of cells, including multiplet detection. Demultiplexing error rates can be estimated, and methods for quality control are provided.

インストール方法を見る

含まれるファイル(1)

  • SKILL.md5.9 KB

SKILL.md(原文)

インストールする前に、エージェントに与えられる指示の中身を確認できます。

demuxmix

Workflows

Standard Workflow

Demultiplex pooled single-cell samples labeled with multiple hashtag oligonucleotides (HTOs) using regression or naive mixture models.

library(demuxmix)

# Simulate a small example dataset
set.seed(2642)
class <- rbind(
  c(rep(TRUE, 220), rep(FALSE, 200)),
  c(rep(FALSE, 200), rep(TRUE, 220))
)
simdata <- dmmSimulateHto(class)
hto <- simdata$hto
rna <- simdata$rna

# Run demuxmix and summarize results
dmm <- demuxmix(hto, rna = rna)
summary(dmm)

# Classify droplets and plot QC histogram
classes <- dmmClassify(dmm)
table(classes$HTO)
plotDmmHistogram(dmm)

Input/Output Note: Inputs an HTO count matrix and a vector of detected genes per droplet; outputs a classified data frame of singlets, multiplets, negatives, and uncertain droplets.

Pooling Non Labeled With Labeled Cells

Demultiplex a mixture of labeled cells and non-labeled cells (e.g., rare cells) using a single HTO channel.

library(demuxmix)
data(csf)

# Filter out low-quality droplets
csf <- csf[csf$NumGenes >= 200, ]
hto <- t(matrix(csf$HTO, dimnames = list(rownames(csf), "HTO")))

# Fit regression mixture model
dmm <- demuxmix(hto, rna = csf$NumGenes)
summary(dmm)
dmmOverlap(dmm)

# Generate QC plots
plotDmmHistogram(dmm)
plotDmmScatter(dmm)

# Classify droplets into labeled (positive) and non-labeled (negative)
class <- dmmClassify(dmm)
table(class$HTO)

Input/Output Note: Inputs a single-channel HTO matrix and a vector of detected genes; outputs classifications separating labeled cells (positive) from non-labeled cells (negative).

When to Use

  • To demultiplex pooled single-cell RNA-seq samples labeled with hashtag oligonucleotides (HTOs) using negative binomial regression mixture models via demuxmix().
  • To leverage the positive association between the number of detected genes per droplet and HTO counts to improve classification accuracy.
  • To identify multiplets and estimate false discovery rates (FDR) using summary().
  • To demultiplex a mixture of labeled cells (e.g., PBMCs) and non-labeled cells (e.g., rare CSF cells) using a single HTO channel.

When NOT to Use

  • For demultiplexing genetically diverse pooled samples without HTOs; use genetic demultiplexing tools like freemuxlet because demuxmix requires HTO count data.
  • For general cell clustering or cell-type annotation; use Seurat or scran because demuxmix is strictly for sample demultiplexing.
  • For processing raw FASTQ files into count matrices; use CellRanger or Alevin because demuxmix requires pre-computed HTO and RNA count matrices.

Data Requirements

  • Input format: A raw HTO count matrix (HTOs as rows, droplets/cells as columns) and a vector of the number of detected genes per droplet (RNA).
  • Structure: Droplets must be pre-filtered to remove empty and low-quality droplets (e.g., using emptyDrops).
  • Normalization: Raw, untransformed integer counts are required for both HTO and gene counts.

Key Parameters

  • rna (NULL): A numeric vector containing the number of detected genes per droplet.
  • model ("regression"): Character string specifying the mixture model type ("regression" or "naive").
  • pAcpt (0.9 or 0.729 depending on model): The minimum posterior probability required to classify a droplet; droplets below this are marked as "uncertain".

Best Practices

  • Remove empty and low-quality droplets using emptyDrops before running demuxmix().
  • Use the default regression mixture model (model = "regression") to leverage the positive correlation between HTO counts and detected genes.
  • Verify the model fit by plotting density histograms overlaid with the mixture probability mass function using plotDmmHistogram().
  • Check the overlap between positive and negative components using dmmOverlap(); an overlap of less than 0.03 indicates excellent separation.

Common Pitfalls

  • Too many "uncertain" classifications: Occurs when HTO quality is moderate or background is high. Fix: Lower the acceptance probability pAcpt (e.g., pAcpt(dmm) <- 0.7 or 0) to force classification, keeping in mind this may increase the error rate.
  • Flat red component in histogram: Occurs when sequencing depth is very high or many samples are pooled. Fix: Use coord_cartesian() to zoom into the critical overlap region of the histogram.
  • Poor regression fit in negative droplets: Occurs when background HTO staining is extremely low. Fix: The package handles this, but you can switch to model = "naive" if the association between HTO and gene counts is absent.

Alternatives

  • hashedDrops (from DropletUtils): For HTO demultiplexing without explicitly modeling the gene-HTO correlation.
  • Seurat (HTODemux): For demultiplexing using a k-medoids clustering approach on normalized HTO counts.
  • freemuxlet: For genetic demultiplexing of pooled samples from genetically unrelated donors.

Citations

  • Stoeckius et al. (2018), Genome Biology.

References

レビュー

まだレビューはありません。使ってみた感想をお寄せください。

同じリポジトリのスキル

概要と使いどころ

The package contains functions for exploratory oligonucleotide array analysis. The dependence on tkWidgets only concerns few convenience functions. 'affy' is fully functional without it.

日本語の概要は準備中です。原文の説明を表示しています。

bioMate-AI/biomate-bioconductor-kb8042026年6月21日 更新

This tool uses the label-tree function from HyPhy to annotate a phylogenetic tree. It allows users to select a subset of leaves using either a regular expression or a list of sequence names, and then apply a specified label to these selecte

日本語の概要は準備中です。原文の説明を表示しています。

bioMate-AI/biomate-bioconductor-kb8042026年6月21日 更新

This package provides a client for the Bioconductor AnnotationHub web resource. The AnnotationHub web resource provides a central location where genomic files (e.g., VCF, bed, wig) and other resources from standard locations (e.g., UCSC, En

日本語の概要は準備中です。原文の説明を表示しています。

bioMate-AI/biomate-bioconductor-kb8042026年6月21日 更新

apeglm provides Bayesian shrinkage estimators for effect sizes for a variety of GLM models, using approximation of the posterior for individual coefficients.

日本語の概要は準備中です。原文の説明を表示しています。

bioMate-AI/biomate-bioconductor-kb8042026年6月21日 更新

ASURAT is a software for single-cell data analysis. Using ASURAT, one can simultaneously perform unsupervised clustering and biological interpretation in terms of cell type, disease, biological process, and signaling pathway activity. Inputting a single-cell RNA-seq data and knowledge-based databases, such as Cell Ontology, Gene Ontology, KEGG, etc., ASURAT transforms gene expression tables into original multivariate tables, termed sign-by-sample matrices (SSMs).

日本語の概要は準備中です。原文の説明を表示しています。

bioMate-AI/biomate-bioconductor-kb8042026年6月21日 更新

AUCell allows to identify cells with active gene sets (e.g. signatures, gene modules...) in single-cell RNA-seq data. AUCell uses the "Area Under the Curve" (AUC) to calculate whether a critical subset of the input gene set is enriched with

日本語の概要は準備中です。原文の説明を表示しています。

bioMate-AI/biomate-bioconductor-kb8042026年6月21日 更新

bioMate-AI のスキルをすべて見る

このスキルの問題を報告する