Coder Social home page Coder Social logo

phenopredict21's Introduction

phenopredict21

Predict phenotypes and/or probabilities of disease from a VCF file on the 21 Bitcoin Computer.

The setup is: you have a genome sequence in a VCF file*, and want to predict the phenotypes of the person who the genome belongs to. This command line tool pulls a phenotype prediction model from an external server that hosts the model in JSON (https://github.com/joepickrell/pheno-server-21) in exchange for BTC and then returns the prediction.

Right now the server only has a model for predicting Alzheimer's disease risk (and note there are lots of caveats to risk prediction, this is intended only as a toy example).

*To obtain your genome sequence, there are a few options (I am not affiliated with any of these except where noted): You could get whole genome sequencing from places like Full Genomes, or get genotyped by companies like 23andMe or AncestryDNA. In the latter case, you will probabably want to do genotype imputation using functionality available from places like DNA.Land (Note: I am affiliated with DNA Land).

Set up

git clone https://github.com/joepickrell/phenopredict21.git

cd phenopredict21

sudo pip3 install .

Run

phenopredict21 --pheno AD --vcf vcf/chr19.vcf.gz

Options

To see a list of available phenotypes, use the --phenos flag:

phenopredict21 --phenos

Right now this will return only "AD", for Alzheimer's disease

To input a VCF file and a phenotype, use --pheno and --vcf, as in the example above

Output

The output is a dict in JSON with the following entries:

  1. 'odds': odds of developing the disease, relative to the average European-descent individual
  2. 'absolute_risk': the absolute probability of developing the disease, calculated using the odds and the baseline probability
  3. 'average_risk': the probability of developing the disease for an average person in the population (this is used as the baseline for calculating the absolute risk, and so this has a large effect on the risk calculation)
  4. 'score': the polygenic risk score for the individual, used to calculate the odds
  5. 'meanscore': the polygenic risk score for an average person of European ancestry
  6. 'ngt': the number of SNPs in the risk prediction model that are also in the VCF file
  7. 'nmiss': the number of SNPs in the risk prediction model that are absent from the VCF file

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.