A Python visualization tool for genomic surveillance
Project description
VARGRAM (Visual ARrays for GRaphical Analysis of Mutations)
🧬 VARGRAM is a Python package that makes it easy to generate insightful figures for genomic surveillance, born out of our experience during the COVID-19 pandemic. With the latest update, VARGRAM can be used to generate mutation profiles straight from sequence files by hooking into existing tools such as Nextclade. The figures can be easily customized within a Python script or Jupyter notebook using a declarative syntax.
🔥 We are actively developing VARGRAM into a full visualization library for common use cases in molecular epidemiology. More modules will be added in the coming months. If you have a feature request or find a bug, please submit an issue.
Installation
A pre-release (but tested) version of VARGRAM is available for download and can already be used. To install with pip, run
pip install --pre vargram
on the command line. Python version ≥3.11 is required.
VARGRAM relies on Nextclade to perform mutation calling when sequence files are provided. Make sure to download the Nextclade CLI and add it to the path.
Full installation instructions are available on the VARGRAM Wiki.
Quickstart Guide
To produce a mutation profile, VARGRAM requires a single FASTA file (or a directory of FASTA files) of samples, a FASTA file for the reference, and a genome annotation file following the GFF3 format.
A mutation profile can be generated in just four lines of code:
from vargram import vargram # Importing the package
vg = vargram(seq='path/to/covid_samples/', # Provide sample sequences
ref='path/to/covid_reference.fa', # Provide reference sequence
gene='path/to/covid_annotation.fa') # Provide genome annotation
vg.profile() # Tell VARGRAM you want to create a mutation profile
vg.show() # And show the resulting figure
Alternatively, you can simply provide a CSV file. For example, you can upload your sequences to the Nextclade web app and download the analysis CSV output. VARGRAM recognizes this output and can process it:
from vargram import vargram
vg = vargram(data='path/to/nextclade_analysis.csv', nextclade=True)
vg.profile()
vg.show()
Calling the mutation profile this way does not require Nextclade CLI to be installed.
Check out the VARGRAM Wiki for more details, including how to customize the figure and produce profiles like the following:
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file vargram-0.1.0b1.tar.gz
.
File metadata
- Download URL: vargram-0.1.0b1.tar.gz
- Upload date:
- Size: 25.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.1 CPython/3.12.4
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 130b94dc6def46f297c0ddb735d5ebce9268ae438354b11f5ffbc93dc57e74a1 |
|
MD5 | a2f757c889d3be794e0a8fb26718f19e |
|
BLAKE2b-256 | e5c8387295b0ced09e9ac5981106dfc5af356b3b4c1926c7ef029393ecfb5f13 |
File details
Details for the file vargram-0.1.0b1-py3-none-any.whl
.
File metadata
- Download URL: vargram-0.1.0b1-py3-none-any.whl
- Upload date:
- Size: 23.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.1 CPython/3.12.4
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | e7c5c9eab14d9cc5848e8c857808c08cd5c3a755ba171c778a2aa40eb61ec081 |
|
MD5 | d8386edcde38da2f3c73af3cc08c5ec8 |
|
BLAKE2b-256 | 6ff8a711c0ab8f2df9556dbc3338095a4a1ced7e9035edb40bafbf65500db0d2 |