Last updated: 2018-06-01

workflowr checks: (Click a bullet for more information)
Expand here to see past versions:


Overview

We provide code to convert association statistics in FastQTL format, or a format similar to FastQTL, to a format that is more convenient for mash analysis. Here we give instructions for using this code, and demonstrate how to convert a toy FastQTL data set. This toy data set is included in the git repository.

To facilitate running our conversion procedure, we have also developed a Docker container that includes all the required software components, including the HDF5 libraries. Docker can run on most popular operating systems (Mac, Windows and Linux) abd cloud computing services such as Amazon Web Services and Microsoft Azure. If you have not used Docker before, you might want to read this to learn the basic concepts and understand the main benefits of Docker.

For details on how the Docker image was configured, see fastqtl2mash.dockerfile in the workflows directory of the git repository. The Docker image used for our analyses is based on gaow/lab-base, a customized Docker image for development with R and Python.

If you find a bug in any of these steps, please post an issue.

Converting eQTL summary statistics to MASH format

Here we explain how the MatrixEQTLSumStats.Portable.Z.rds data file was generated from the source data downloaded from the GTEx Portal. The source data are the SNP-gene association statistics from release 6 of the GTEx Project (GTEx_Analysis_V6_all-snp-gene-associations.tar).

Under the repo you will find workflows/fastqtl_to_mash.ipynb to convert eQTL summary statistics (default to fastqtl format) to MASH format. Computation is configured to run in parallel for eQTL results from multiple studies. Example data-set can be found at data/eQTLDataDemo. The workflow file is documented in itself, and has a few options to customize the input and output.

To read what’s available, run:

mash-docker sos run workflows/fastqtl_to_mash.ipynb export

and read the HTML files output/fastqtl_to_mash.lite.html and output/fastqtl_to_mash.full.html

To run the conversion:

mash-docker sos run workflows/fastqtl_to_mash.ipynb \
  --data_list data/eQTLDataDemo/FastQTLSumStats.list \
  --gene_list data/eQTLDataDemo/GTEx_genes.txt

In practice for GTEx data the conversion is computationally intensive and is best done on a cluster environment with configurations to run the workflow across different nodes.


This reproducible R Markdown analysis was created with workflowr 1.0.1.9000