pkg <- read.dcf("DESCRIPTION", fields = "Package")[1] description <- read.dcf("DESCRIPTION", fields = "Description")[1]
r pkg
: r gsub("echoverse module: ","", description)
r pkg
is part of the echoverse, a suite of R packages designed to facilitate different steps in genetic fine-mapping.
r pkg
calls each of these other packages (i.e. "modules") internally to create a unified pipeline. However, you can also use each module independently to create your own custom workflows.
Made with
echodeps
, yet another echoverse module. See here for the interactive version with package descriptions and links to each GitHub repo.
If you use r pkg
, or any of the echoverse modules, please cite:
r citation(pkg)$textVersion
if(!require("remotes")) install.packages("remotes") remotes::install_github("RajLabMSSM/`r pkg`") library(`r pkg`)
echolocatoR
now relies on many subpackages that rely on one another,
sometimes errors can occur when R tries to update one R package before
updating its echoverse dependencies (and thus is unable to find new functions).
As echoverse stabilizes over time, this should happen less frequently. However,
in the meantime the solution is to simply rerun
remotes::install_github("RajLabMSSM/echolocatoR")
until all subpackages are fully updates. susieR
: Sometimes an older version of susieR
is installed from CRAN (e.g. 0.11.92), but echofinemap
requires version >= 0.12.0. To get around this, you can install susieR
directly from GitHub: devtools::install_github("stephenslab/susieR")
XML
(which some echoverse subpackages depend on) has some additional system dependencies that must be installed beforehand.
If XML
does not install automatically, try installing lbxml
on your system using brew install libxml2
(MacOS),
sudo apt-get install libxml2
(Linux) or
conda install r-xml
if you are running echolocatoR
from within a
conda environment. echolocatoR
now has its own dedicated Docker/Singularity container!
This greatly reduces issues related to system dependency conflicts and provides a containerized interface for Rstudio through your web browser. See here for installation instructions.
Please report any bugs/requests on GitHub Issues.
Contributions are welcome!
echoverse <- c('echolocatoR','echodata','echotabix', 'echoannot','echoconda','echoLD', 'echoplot','catalogueR','downloadR', 'echofinemap','echodeps', # under construction 'echogithub') toc <- echogithub::github_pages_vignettes(owner = "RajLabMSSM", repo = echoverse, as_toc = TRUE, verbose = FALSE)
Fine-mapping methods are a powerful means of identifying causal variants
underlying a given phenotype, but are underutilized due to the technical
challenges of implementation. r pkg
is an R package that
automates end-to-end genomics fine-mapping, annotation, and plotting in
order to identify the most probable causal variants associated with a
given phenotype.
It requires minimal input from users (a GWAS or QTL summary statistics file), and includes a suite of statistical and functional fine-mapping tools. It also includes extensive access to datasets (linkage disequilibrium panels, epigenomic and genome-wide annotations, QTL).
The elimination of data gathering and preprocessing steps enables rapid
fine-mapping of many loci in any phenotype, complete with locus-specific
publication-ready figure generation. All results are merged into a
single per-SNP summary file for additional downstream analysis and
results sharing. Therefore r pkg
drastically reduces the
barriers to identifying causal variants by making the entire
fine-mapping pipeline rapid, robust and scalable.
r pkg
in the literature, please see:
- E Navarro, E Udine, K de Paiva Lopes, M Parks, G Riboldi, BM Schilder…T Raj (2020) Dysregulation of mitochondrial and proteo-lysosomal genes in Parkinson's disease myeloid cells. Nature Genetics. https://doi.org/10.1101/2020.07.20.212407
- BM Schilder, T Raj (2021) Fine-Mapping of Parkinson’s Disease Susceptibility Loci Identifies Putative Causal Variants. Human Molecular Genetics, ddab294, https://doi.org/10.1093/hmg/ddab294
- K de Paiva Lopes, G JL Snijders, J Humphrey, A Allan, M Sneeboer, E Navarro, BM Schilder…T Raj (2022) Genetic analysis of the human microglial transcriptome across brain regions, aging and disease pathologies. Nature Genetics, https://doi.org/10.1038/s41588-021-00976-y
echolocatoR
v1.0 vs. v2.0There have been a series of major updates between echolocatoR
v1.0 and v2.0. Here are some of the most notable ones (see Details):
echolocatoR
has been broken into separate subpackages, making it much easier to edit/debug each step of the full finemap_loci
pipeline, and improving robustness throughout. It also provides greater flexibility for users to construct their own custom pipelines from these modules.GITHUB_TOKEN
: GitHub now requires users to create Personal Authentication Tokens (PAT) to avoid download limits. This is essential for installing echolocatoR
as many resources from GitHub need to be downloaded. See here for further instructions.
= echodata::construct_colmap()
: Previously, users were required to input key column name mappings as separate arguments to echolocatoR::finemap_loci
. This functionality has been deprecated and replaced with a single argument, colmap=
. This allows users to save the construct_colmap()
output as a single variable and reuse it later without having to write out each mapping argument again (and helps reduce an already crowded list of arguments). MungeSumstats
: finemap_loci
now accepts the output of MungeSumstats::format_sumstats
/import_sumstats
as-is (without requiring colmap=
, so long as munged=TRUE
). Standardizing your GWAS/QTL summary stats this way greatly reduces (or eliminates) the time taken to do manual formatting. echolocatoR::finemap_loci
arguments: Several arguments have been deprecated or had their names changed to be harmonized across all the subpackages and use a unified naming convention. See ?echolocatoR::finemap_loci
for details. echoconda
: The echoverse subpackage echoconda
now handles all conda environment creation/use internally and automatically, without the need for users to create the conda environment themselves as a separate step. Also, the default conda env echoR
has been replaced by echoR_mini
, which reduces the number of dependencies to just the bare minimum (thus greatly speeding up build time and reducing potential version conflicts). FINEMAP
: More outputs from the tool FINEMAP
are now recorded in the echolocatoR
results (see ?echofinemap::FINEMAP
or this Issue for details). Also, a common dependency conflict between FINEMAP
>=1.4 and MacOS has been resolved (see this Issue for details. echodata
: All example data and data transformation functions have been moved to the echoverse subpackage echodata
. LD_reference=
: In addition to the UKB, 1KGphase1/3 LD reference panels,
finemap_loci()
can now take custom LD panels by supplying
finemap_loci(LD_reference=)
with a
list of paths to VCF files (.vcf / vcf.gz / vcf.bgz) or
pre-computed LD matrices with RSIDs as the row/col names
(.rda / .rds / .csv / .tsv. / .txt / .csv.gz / tsv.gz / txt.gz).FINEMAP
fixed: There were a number of issues with FINEMAP
due to differing output formats across different versions, system dependency conflicts, and the fact that it can produce multiple Credible Sets. All of these have been fixed and the latest version of FINEMAP
can be run on all OS platforms. finemap_loci()
I use a tryCatch()
when iterating across loci so that if one locus fails, the rest can continue. However this prevents using traceback feature in R, making debugging hard. Thus I now enabled debugging mode via a new argument: use_tryCatch=FALSE
. By default, echolocatoR::finemap_loci()
returns a nested list containing grouped by locus names (e.g. $BST1
, $MEX3C
). The results of each locus contain the following elements:
finemap_dat
: Fine-mapping results from all selected methods merged with the original summary statistics (i.e. Multi-finemap results). locus_plot
: A nested list containing one or more zoomed views of locus plots. LD_matrix
: The post-processed LD matrix used for fine-mapping.LD_plot
: An LD plot (if used).locus_dir
: Locus directory results are saved in. arguments
: A record of the arguments supplied to finemap_loci
. In addition, the following object summarizes the results from the locus-specific elements:
- merged_dat
: A merged data.table
with all fine-mapping
results from all loci.
The main output of echolocatoR
are the multi-finemap files (for
example, echodata::BST1
). They are stored in the locus-specific
Multi-finemap subfolders.
SNP
,CHR
,POS
,Effect
,StdErr
. See ?finemap_loci()
for
descriptions of each. NA
(or 0
for the
purposes of plotting). N
fine-mapping tool(s), i.e. Support>1
(default: N=1
). mean.PP>0.95
) then mean.CS
is 1, else 0. This tends
to be a very stringent threshold as it requires a high degree of
agreement between fine-mapping tools.Fine-mapping functions are now implemented via echofinemap
:
r pkg
will automatically check whether you have the
necessary columns to run each tool you selected in
echolocatoR::finemap_loci(finemap_methods=...)
.
It will remove any tools that for
which there are missing necessary columns, and produces a message
letting you know which columns are missing.MAF
,N
,t-stat
) will be automatically inferred if missing. ?echodata::construct_colmap()
for descriptions of these columns.SNP
,CHR
,POS
,Effect
,StdErr
fm_methods <- echofinemap::required_cols(add_versions = FALSE, embed_links = TRUE, verbose = FALSE) knitr::kable(x = fm_methods)
Datasets are now stored/retrieved via the following echoverse subpackages:
- echodata
: Pre-computed fine-mapping results. Also handles the semi-automated standardization of summary statistics.
- echoannot
: Annotates GWAS/QTL summary statistics using epigenomics, pre-compiled annotation matrices, and machine learning model predictions of variant-specific functional impacts.
- catalogueR
: Large compendium of fully standardized e/s/t-QTL summary statistics.
For more detailed information about each dataset, use ?
:
### Examples ### library(echoannot) ?NOTT_2019.interactome # epigenomic annotations library(echodata) ?BST1 # fine-mapping results
MungeSumstats
:MungeSumstats
, specifically the functions find_sumstats
and import_sumstats
. catalogueR
: QTLscatalogueR::eQTL_Catalogue.query()
catalogueR
R package.echodata
: fine-mapping resultsechodata::portal_query()
. echoannot
: Epigenomic & genome-wide annotationsechoannot::NOTT2019_*()
echoannot::CORCES2020_*()
FitHiChIP
) from postmortem adult human brain tissue.echoannot::XGR_download_and_standardize()
echoannot::ROADMAP_query()
echoannot::annotate_snps()
echoannot::annotate_snps()
Annotation enrichment functions are now implemented via echoannot
:
echoannot::XGR_enrichment()
echoannot::MOTIFBREAKR()
echoannot::test_enrichment()
GRangesList
objects.
LD reference panels are now queried/processed by echoLD
,
specifically the function get_LD()
:
Plotting functions are now implemented via:
- echoplot
: Multi-track locus plots with GWAS, fine-mapping results, and functional annotations (plot_locus()
). Can also plot multi-GWAS/QTL and multi-ancestry results (plot_locus_multi()
).
- echoannot
: Study-level summary plots showing aggregted info across many loci at once (super_summary_plot()
).
- echoLD
: Plot an LD matrix using one of several differnt plotting methods (plot_LD()
).
All queries of tabix
-indexed files (for rapid data subset extraction) are implemented via echotabix
.
echotabix::convert_and_query()
detects whether the GWAS summary statistics file you provided is already tabix
-indexed, and it not, automatically performs all steps necessary to convert it (sorting, bgzip
-compression, indexing) across a wide variety of scenarios. echotabix::query()
contains many different methods for making tabix queries (e.g. Rtracklayer
,echoconda
,VariantAnnotation
,seqminer
), each of which fail in certain circumstances. To avoid this, query()
automatically selects the method that will work for the particular file being queried and your machine's particular versions of R/Bioconductor/OS, taking the guesswork and troubleshooting out of tabix
queries. Single- and multi-threaded downloads are now implemented via downloadR
.
axel
, and is particularly useful for speeding up downloads of large files. axel
is installed via the official echoverse conda environment: "echoR_mini". This environment is automatically created by the function echoconda::yaml_to_env()
when needed.
Brian
M. Schilder, Bioinformatician II
Raj Lab
Department
of Neuroscience, Icahn School of Medicine at Mount Sinai
utils::sessionInfo()
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.