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

bioconductor-ggmanh

Manhattan plot and QQ Plot are commonly used to visualize the end result of Genome Wide Association Study. The "ggmanh" package aims to keep the generation of these plots simple while maintaining customizability. Main functions include manhattan_plot, qqunif, and thinPoints.

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

설치 방법 보기

포함된 파일(1)

  • SKILL.md5.3 KB

SKILL.md(원문)

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

ggmanh

Workflows

Standard Workflow

library(ggmanh)
# Format chromosome column as a factor
simdata$chromosome <- factor(simdata$chromosome, c(1:22,"X"))
# Generate standard Manhattan plot
g1 <- manhattan_plot(x = simdata, pval.colname = "P.value", chr.colname = "chromosome", pos.colname = "position")
# Generate rescaled Manhattan plot
g2 <- manhattan_plot(x = simdata, pval.colname = "P.value", chr.colname = "chromosome", pos.colname = "position", rescale = TRUE)
# Preprocess data
mpdata <- manhattan_data_preprocess(x = simdata, pval.colname = "P.value", chr.colname = "chromosome", pos.colname = "position")
# Generate plots using preprocessed data with labels
g3 <- manhattan_plot(x = mpdata, label.colname = "label")
# Zoom into Chromosome 5
manhattan_plot(simdata, chromosome = 5, pval.colname = "P.value", chr.colname = "chromosome", pos.colname = "position")

Note: Input is a data frame of GWAS summary statistics; output is a customized Manhattan plot object.

Binned Manhattan Plot

library(ggmanh)
# Basic Binned Manhattan Plot
binned_manhattan_plot(simdata, pval.colname = "P.value", chr.colname = "chromosome", pos.colname = "position")
# Preprocess binned data
mpdat <- binned_manhattan_preprocess(simdata, pval.colname = "P.value", chr.colname = "chromosome", pos.colname = "position", bins.x = 7, bins.y = 100)
# Plot preprocessed binned data
binned_manhattan_plot(mpdat, bin.outline = TRUE)

Note: Input is a data frame of GWAS summary statistics; output is a binned grid-based Manhattan plot.

Gds Variant Annotation Plotting

library(ggmanh)
# Annotate variants using gds_annotate
simdata_label$label <- gds_annotate(x = simdata_label, annot.method = "position", chr = "chromosome", pos = "position", ref = "Reference", alt = "Alternate")
# Plot annotated data
manhattan_plot(simdata_label, pval.colname = "P.value", chr.colname = "chromosome", pos.colname = "position", label.colname = "label")

Note: Inputs are a data frame of GWAS summary statistics and a GDS file; output is an annotated Manhattan plot.

When to Use

  • To visualize Genome Wide Association Study (GWAS) results using standard Manhattan plots (manhattan_plot).
  • To rescale the y-axis of a Manhattan plot when highly significant p-values mask lower-significance patterns (rescale = TRUE).
  • To create binned grid-based Manhattan plots for extremely large datasets to avoid plotting individual points (binned_manhattan_plot).
  • To annotate variants with gene/consequence information from a GDS file using gds_annotate.

When NOT to Use

  • When using discrete palettes for continuous variables (or vice versa) in binned_manhattan_plot, as the plot will fail.

Data Requirements

  • Input data frame: Must contain at least three columns representing chromosome, position, and p-value.
  • Chromosome column: Recommended to be formatted as a factor to avoid ambiguity in plotting order.
  • GDS file: For variant annotation, a SeqArray-formatted GDS file containing annotations (e.g., annotation/symbol, annotation/consequence).

Key Parameters

  • x: A data.frame, MPdata, or GRanges object containing the GWAS results.
  • pval.colname: Name of the column containing p-values.
  • chr.colname: Name of the column containing chromosomes.
  • pos.colname: Name of the column containing genomic positions.
  • rescale (FALSE): Logical indicating whether to rescale the y-axis near the significance cutoff.
  • label.colname: Name of the column containing labels for annotation.
  • chromosome: Specific chromosome number/name to zoom into.
  • bins.x: Number of horizontal bins for the widest chromosome in binned plots.

Best Practices

  • Convert the chromosome column to a factor before plotting to ensure correct ordering on the x-axis.
  • Preprocess data using manhattan_data_preprocess or binned_manhattan_preprocess first if you plan to customize the plot multiple times, avoiding redundant computation.
  • Set non-significant labels to "" or NA to avoid overlapping labels and extremely slow plotting times.

Common Pitfalls

  • Attempting to label all points: This can cause the plotting process to take hours. Set labels for non-significant points to "" or NA.
  • Using incompatible palettes: Ensure continuous palettes are used for continuous variables and discrete palettes for discrete variables in binned_manhattan_plot.

Alternatives

  • qqman for basic Manhattan and QQ plots.

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-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의 스킬 모두 보기

이 스킬의 문제 신고