Code Monkey home page Code Monkey logo

multigroup_ctwas's Introduction

ctwas: an R package for integrating molecular QTLs and GWAS for gene discovery

Expression Quantitative Trait Loci (eQTLs) have often been used to nominate candidate genes from Genome-wide association studies (GWAS). However, commonly used methods are susceptible to false positives largely due to Linkage Disequilibrium (LD) of eQTLs with causal variants acting on the phenotype directly.

Our method, "causal-TWAS" (cTWAS), addresses this challenge by borrowing ideas from statistical fine-mapping. It is a generalization of methods for transcriptome-wide association studies (TWAS), but when analyzing any gene, it adjusts for other nearby genes and all nearby genetic variants.

While the published paper analyzes a single eQTL dataset, the latest version of cTWAS extends the method to integrate multiple groups of prediction models, allowing for joint analysis of multiple types of molecular traits, across potentially different tissues, cell types or conditions.

Install ctwas

Use "remotes" to install the latest version of ctwas from GitHub:

install.packages("remotes")
remotes::install_github("xinhe-lab/ctwas",ref = "multigroup_test")

Currently, ctwas has only been tested on Linux systems.

We recommend installing and running ctwas on a high-performance computing system.

Running ctwas

Running a cTWAS analysis involves four main steps:

  1. Preparing the input data.

  2. Computing the gene z-scores.

  3. Estimating the model parameters.

  4. Fine-mapping.

The outputs of cTWAS are posterior inclusion probabilities (PIPs) for all variants and molecular traits.

To learn more about the ctwas R package, we recommend starting with this introductory tutorial:

A minimal tutorial of how to run cTWAS without LD

To run the full cTWAS, a few more tutorials including:

You can browse source code and report a bug here.

Citing this work

If you find the ctwas package or any of the source code in this repository useful for your work, please cite:

Zhao S, Crouse W, Qian S, Luo K, Stephens M, He X. Adjusting for genetic confounders in transcriptome-wide association studies improves discovery of risk genes of complex traits. Nature Genetics 56, 336โ€“347 (2024). https://doi.org/10.1038/s41588-023-01648-9

Useful resources

We have pre-computed the LD matrices of European samples from UK Biobank. They can be downloaded here.

We have the lists of reference variant information from all the LD matrices in the genome in hg38 and hg19.

cTWAS requires the expression prediction models, or weights, of genes. The pre-computed weights of GTEx expression and splicing traits can be downloaded from PredictDB.

Acknowledgments

We thank the authors of susieR package for using their codes.

Original susieR code obtained by:

git clone [email protected]:stephenslab/susieR.git
git checkout c7934c0

Minor edits to make it accept different prior variances for each variable.

multigroup_ctwas's People

Contributors

kevinlkx avatar simingz avatar pcarbo avatar sq-96 avatar wesleycrouse avatar shugamoe avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.