본문으로 건너뛰기
cccskills
무료GitHub에 공개

bioconductor-busseq

BUSseq R package fits an interpretable Bayesian hierarchical model---the Batch Effects Correction with Unknown Subtypes for scRNA seq Data (BUSseq)---to correct batch effects in the presence of unknown cell types. BUSseq is able to simultaneously correct batch effects, clusters cell types, and takes care of the count data nature, the overdispersion, the dropout events, and the cell-specific sequencing depth of scRNA-seq data. After correcting the batch effects with BUSseq, the corrected value ca

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

설치 방법 보기

포함된 파일(1)

  • SKILL.md5.8 KB

SKILL.md(원문)

설치하기 전에 에이전트에게 전달되는 지시 내용을 확인할 수 있습니다.

BUSseq

Workflows

Standard Workflow

Correct batch effects, cluster unknown cell types, identify intrinsic genes, and obtain batch-corrected expression data from multi-batch scRNA-seq count data.

library(BUSseq)
library(SingleCellExperiment)

# 1. Read user input files and prepare data
CountData <- assay(BUSseqfits_example, "counts")
batch_ind <- unlist(colData(BUSseqfits_example))

sce_input <- SingleCellExperiment(
  assays = list(counts = CountData),
  colData = DataFrame(Batch_ind = factor(batch_ind))
)

# 2. Conduct MCMC sampling and posterior inference
BUSseqfits_res <- BUSseq_MCMC(
  ObservedData = sce_input, 
  seed = 1234, 
  n.cores = 2,
  n.celltypes = 4, 
  n.iterations = 500
)

# 3. Extract the imputed read counts, estimated cell types, and batch effects
Imputed_count <- assay(BUSseqfits_res, "imputed_data")
celltyes_est <- celltypes(BUSseqfits_res)
location_batch_effects_est <- location_batch_effects(BUSseqfits_res)
overdispersion_est <- overdispersions(BUSseqfits_res)
cell_effects_est <- cell_effect_values(BUSseqfits_res)
celltype_effects_est <- celltype_effects(BUSseqfits_res)

# 4. Identify intrinsic genes that drive cell-type differences
intrinsic_gene_indicators <- intrinsic_genes_BUSseq(BUSseqfits_res)
index_intri <- which(unlist(intrinsic_gene_indicators) == "Yes")

# 5. Compute and incorporate batch-corrected read counts
BUSseqfits_res <- corrected_read_counts(BUSseqfits_res)

# 6. Visualize the raw, imputed, and corrected expression data
heatmap_data_BUSseq(BUSseqfits_res, data_type = "Raw", 
                    project_name = "BUSseq_raw_allgenes",
                    image_dir = "./heatmap")
heatmap_data_BUSseq(BUSseqfits_res, data_type = "Imputed", 
                    project_name = "BUSseq_imputed_allgenes",
                    image_dir = "./heatmap")
heatmap_data_BUSseq(BUSseqfits_res, data_type = "Corrected",
                    project_name = "BUSseq_corrected_allgenes",
                    image_dir = "./heatmap")

Note: Input is a SingleCellExperiment object containing raw counts and batch indicators; output is a SingleCellExperiment object containing imputed and batch-corrected assays.

When to Use

  • To simultaneously correct batch effects and cluster cells into unknown cell types using single-cell RNA-seq data.
  • To model count data overdispersion and dropout events using a Bayesian hierarchical model.
  • To identify intrinsic genes driving cell-type differences using intrinsic_genes_BUSseq.
  • To extract cell-type-specific mean expression levels using celltype_mean_expression and batch-corrected counts using corrected_read_counts.

When NOT to Use

  • For normalized or log-transformed expression data; use packages like limma or ComBat because BUSseq requires raw count data to model the negative binomial distribution and dropout events.
  • When the gene sets differ across batches; all input batches must have the exact same genes.

Data Requirements

  • Raw count data formatted as a SingleCellExperiment object with a "counts" assay, or as a list of matrices where each element represents a batch.
  • Batch indicators provided as a factor in colData of the SingleCellExperiment object.

Key Parameters

  • ObservedData: A SingleCellExperiment object or a list representing the raw count data.
  • seed (1234): Random seed for reproducible MCMC sampling.
  • n.cores (2): Number of CPU cores to use for parallel computing.
  • n.celltypes (4): The specified number of cell types present in the population.
  • n.iterations (500): Total number of MCMC iterations.
  • n.burnin (n.iterations/2): Number of burn-in iterations discarded before posterior inference.
  • data_type ("Raw"): The type of data to plot in heatmap_data_BUSseq ("Raw", "Imputed", or "Corrected").

Best Practices

  • Ensure that the gene numbers and gene names of all batches are identical before running BUSseq_MCMC.
  • If the number of cell types is unknown, vary n.celltypes and use the Bayesian Information Criterion (BIC) to select the optimal number.
  • Use corrected_read_counts to obtain batch-corrected expression data for downstream analyses.

Common Pitfalls

  • MCMC chain fails to converge: Increase n.iterations and adjust n.burnin to ensure proper posterior sampling.
  • High false discovery rate in intrinsic gene identification: Adjust the FDR threshold or increase the number of iterations to improve posterior estimation.

Alternatives

  • Seurat for alternative single-cell integration and clustering.
  • scater for single-cell QC and visualization.
  • scran for single-cell normalization and pooling.

Citations

  • Song, F., Chan, G. M., & Wei, Y. (2020). Flexible and interpretable Bayesian hierarchical model for batch effect correction in scRNA-seq.

References

리뷰

아직 리뷰가 없습니다. 사용해 본 소감을 남겨 주세요.

댓글

로그인 없이 쓸 수 있습니다. 사용 후기, 질문, 작동하지 않은 환경 등을 편하게 남겨 주세요.

아직 댓글이 없습니다. 첫 댓글을 남겨 보세요.

보내면 바로 공개됩니다. 이메일 주소나 전화번호 같은 개인 정보는 쓰지 마세요. URL은 2개까지입니다.

0 / 1,000자

이 양식은 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-kb7972026년 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-kb7972026년 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-kb7972026년 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-kb7972026년 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-kb7972026년 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-kb7972026년 6월 21일 업데이트

bioMate-AI의 스킬 모두 보기

이 스킬의 문제 신고