跳到正文
cccskills
免费在 GitHub 公开

bioconductor-condiments

This package encapsulate many functions to conduct a differential topology analysis. It focuses on analyzing an 'omic dataset with multiple conditions. While the package is mostly geared toward scRNASeq, it does not place any restriction on the actual input format.

中文简介正在准备中。当前显示原文说明。

查看安装方法

包含的文件(1)

  • SKILL.md6.1 KB

SKILL.md(原文)

安装前可以查看交给 AI 代理的指令内容。

condiments

Workflows

Standard Workflow

Perform differential topology, progression, and fate selection analysis on single-cell data across multiple conditions.

library(condiments)
library(slingshot)
library(dplyr)

# Load toy dataset
data("toy_dataset", package = "condiments")
df <- toy_dataset$sd

# 1. Compute imbalance scores
scores <- imbalance_score(
  Object = df %>% select(Dim1, Dim2) %>% as.matrix(),
  conditions = df$conditions
)
df$scores <- scores$scores
df$scaled_scores <- scores$scaled_scores

# 2. Infer a common trajectory using slingshot
rd <- as.matrix(df[, c("Dim1", "Dim2")])
sds <- slingshot(rd, df$cl)

# 3. Test trajectory topology
top_res <- topologyTest(sds = sds, conditions = df$conditions, rep = 10)

# 4. Test for differential progression along lineages
prog_res <- progressionTest(sds, conditions = df$conditions, global = TRUE, lineages = TRUE)

# 5. Test for differential fate selection between lineages
dif_res <- fateSelectionTest(sds, conditions = df$conditions, global = FALSE, pairwise = TRUE)

Note on inputs/outputs: Input is a cell metadata data frame containing reduced dimensions and condition assignments; outputs are statistical test tables assessing differences in topology, progression, and fate selection between conditions.

When to Use

  • Differential Topology Analysis: Determine if a common trajectory can be fitted across conditions or if separate trajectories are required using topologyTest.
  • Differential Progression Analysis: Test if cells from different conditions are equally represented along pseudotime within a lineage using progressionTest.
  • Differential Fate Selection: Assess whether cells differentiate preferentially along specific lineages across different conditions using fateSelectionTest.
  • Imbalance Score Estimation: Identify regions of local condition imbalance in a reduced dimensional space using imbalance_score.

When NOT to Use

  • Gene-Level Differential Expression: For testing individual gene expression changes along a trajectory, use tradeSeq (specifically fitGAM and conditionTest) instead of condiments directly.
  • Strong Topology Disruption: If topologyTest rejects the null hypothesis, do not fit a common trajectory; instead, infer separate trajectories for each condition.

Data Requirements

  • Reduced Dimensions: A matrix of coordinates in a reduced dimension space (e.g., PCA, UMAP, t-SNE).
  • Condition Labels: A vector assigning each cell to a specific condition (e.g., "A" or "B").
  • Cluster Labels: Cell cluster assignments for trajectory construction.
  • Example Structure:
    data("toy_dataset", package = "condiments")
    df <- toy_dataset$sd
    rd <- as.matrix(df[, c("Dim1", "Dim2")])
    conditions <- df$conditions
    cl <- df$cl
    

Key Parameters

  • Object: A matrix of reduced dimensions passed to imbalance_score.
  • conditions: A vector of condition assignments for each cell.
  • sds: A PseudotimeOrdering object (from slingshot) representing the inferred trajectory.
  • rep (100): Number of permutations used to generate trajectories under the null in topologyTest.
  • methods ("KS_mean"): The test method(s) to use in topologyTest (e.g., "KS_mean", "Classifier", "wasserstein_permutation").
  • global (TRUE): Logical indicating whether to run a global test pooling all lineages in progressionTest or fateSelectionTest.
  • lineages (TRUE): Logical indicating whether to test every lineage independently in progressionTest.
  • pairwise (TRUE): Logical indicating whether to test every pair of lineages independently in fateSelectionTest.

Best Practices

  • Check Integration Quality: Compute local imbalance scores using imbalance_score to verify if integration was successful (some regions should be balanced).
  • Pre-test Topology: Always run topologyTest before downstream differential analysis to justify fitting a common trajectory.
  • Multiple Testing Correction: Correct the resulting p-values from progressionTest and fateSelectionTest for multiple testing, especially for trajectories with a large number of lineages.
  • Treat P-values as Suggestions: Trajectory inference is at the end of a long pipeline; do not put absolute faith in raw p-values and treat them as exploratory suggestions.

Common Pitfalls

  • Slow Execution of Topology Test: topologyTest can be slow on large datasets; mitigate this by reducing the rep parameter or enabling parallelization with parallel = TRUE and a configured BPPARAM.
  • Noisy Imbalance Scores: Raw imbalance scores can be noisy; use the smooth argument in imbalance_score to obtain smoothed, scaled scores.
  • Over-interpreting Uncorrected P-values: Trajectory tests make multiple comparisons; always apply multiple testing correction to avoid false positives.

Alternatives

  • slingshot: For basic trajectory inference without condition-level differential topology tests.
  • tradeSeq: For gene-level differential expression analysis along trajectories using fitGAM and conditionTest.
  • scater / scran: For upstream single-cell preprocessing, normalization, and dimensionality reduction.

Citations

  • Street et al. 2018, BMC Genomics (Slingshot trajectory inference)
  • Van den Berge et al. 2020, Nature Communications (tradeSeq differential expression)
  • Lopez-Paz and Oquab 2016, Arxiv (Classifier two-sample tests)
  • Smirnov 1939, Bull. Math. Univ. Moscou (Kolmogorov-Smirnov test)

References

评价

还没有评价。欢迎分享你的使用感受。

评论

无需登录即可发表。欢迎分享使用感受、提问,或说明在哪些环境下无法运行。

还没有评论。来写第一条吧。

提交后会立即公开。请勿填写邮箱、电话等个人信息。URL 最多 2 个。

0 / 1000 字

此表单受 reCAPTCHA 保护,适用 Google 的隐私权政策和服务条款。

同一仓库的技能

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-kb7932026年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-kb7932026年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-kb7932026年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-kb7932026年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-kb7932026年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-kb7932026年6月21日 更新

查看 bioMate-AI 的全部技能

报告此技能的问题