library(catalogueR)
eQTL Catalogue includes a large number of standardized QTL datasets (110 datasets from 20 studies as of 7/4/2020). It actually contains more than just eQTL data. For each dataset, the following kinds of QTLs can be queried:
quant_method="ge"
(default) or quant_method="microarray"
, depending on the dataset. catalogueR will automatically select whichever option is available. quant_method="ge"
quant_method="tx"
quant_method="txrev"
You can view of a metadata table for all current datasets:
data("meta") messager("There are",formatC(nrow(meta),big.mark = ","), "datasets in eQTL Catalogue.") knitr::kable(meta[1:10,])
You can seach through the metadata for datasets with certain keywords (case-insensitive substrings across multiple columns).
qtl_datasets <- catalogueR::eQTLcatalogue_search_metadata( qtl_search=c("Alasoo_2018","monocyte")) print(qtl_datasets)
Supply one or more paths to [GWAS] summary stats files (one per locus) and automatically download any eQTL data within that range. The files can be any of these formats, either gzip-compressed (.gz
) or uncompressed: .csv
, .tsv
, space-separated
The summary stats files must have the following column names (order doesn't matter):
- SNP
(rsid for each SNP)
- CHR
(chromosome; with or without the "chr" prefix is fine)
- POS
(basepair position)
- ... (optional extra columns)
sumstats_paths <- echodata::get_Nalls2019_loci(limit_snps = 5) gwas.qtl_paths <- catalogueR::eQTLcatalogue_query( sumstats_paths = sumstats_paths["BST1"], qtl_search = c("Alasoo_2018.macrophage_naive"), split_files = TRUE)
split_files=TRUE
the query results have been distributed across multiple files and saved to disk (useful when you don't want to load one massive data.table every time you want to look at specific results subsets). eQTLcatalogue_query()
returns a list of those file paths (instead of the data.table itself). GWAS.QTL <- catalogueR::merge_files(file_paths = gwas.qtl_paths) # Interactive datatable of results ## WARNING: Don't use this function on large datatables, might cause freezing. echodata::createDT(utils::head(GWAS.QTL))
You can also makes queries to eQTL Catalogue by manually specifying the coordinates of the region you want to extract,
as well as the unique_id
of the QTL dataset (see data("meta")
for IDs).
GWAS.QTL_manual <- catalogueR:: eQTLcatalogue_fetch( unique_id="Alasoo_2018.macrophage_IFNg", chrom = 8, bp_lower = 21527069-500, bp_upper = 21527069+500) echodata::createDT(utils::head(GWAS.QTL_manual))
utils::sessionInfo()
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.