lisaiceland / ezancestry

Visualize your genotype data with streamlit

Home Page:http://ezancestry.herokuapp.com/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

ezancestry

One Thousand Genomes Project -- Population Visualizations using Streamlit

ezancestry is an interactive visualization app built in Python with Streamlit and deployed on Heroku.

Visualize you genotypes at http://ezancestry.herokuapp.com/

image

Local Installation and Usage

ezancestry can be installed locally:

  1. Download ezancestry

  2. Change into the ezancestry directory:

    $ cd ezancestry
    
  3. Create a virtual environment:

    $ python -m venv .venv
    
  4. Activate the virtual environment:

    $ source .venv/bin/activate
    
  5. Install required packages:

    (.venv) $ pip install -r requirements.txt
    

    If issues installing cyvcf2, see here. Setting these environment variables might work (if openssl installed with MacPorts):

    export LDFLAGS="-L/opt/local/include"
    export PKG_CONFIG_PATH="/opt/local/include"
    export CPPFLAGS="-I/opt/local/include"
    
  6. Run ezancestry:

    (.venv) $ streamlit run app.py
    

    You will then be presented with a URL to use the app in a browser.

  7. Ctrl-C to stop the web server

  8. Deactivate the virtual environment:

    (.venv) $ deactivate
    

Run ezancestry on openSNP data!

Thanks to Andrew Riha, it's easy to predict the ancestries for all of the openSNP samples:

  1. Download the data to the data directory. It's a large zipped directory!
  2. Follow steps 1-5 above.
  3. Run python opensnp_ancestry.py and wait for the results.

openSNP

About

Visualize your genotype data with streamlit

http://ezancestry.herokuapp.com/

License:MIT License


Languages

Language:Python 99.3%Language:Shell 0.7%