Explore omics data without leaving the terminal.
Light, blazing fast ๐, vim motion, memory safe.
https://github.com/user-attachments/assets/ce33b31d-d3eb-4395-9ab4-ab3a501aa1be
(TGV is at an early statge. Please don't rely your papers on it (yet) :)
Contribution and bug reports are welcome! Please join the Discord to discuss ideas.)
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh
# Add Rust to your path (or restart your terminal):
source "$HOME/.cargo/env"cargo install tgv# Clone the repository
git clone https://github.com/zeqianli/tgv.git
cd tgv
cargo install --path .# Browse the hg38 human genome. Internet connection required.
tgv- Quit:
:q - Movement:
- Left / down / up / right:
h/j/k/l: - Faster left / right:
y/p - Next gene / previous gene / next exon / previous exon:
W/B/w/b - Repeat movements:
_number_+_movement_(e.g.20B: left by 20 genes)
- Left / down / up / right:
- Zoom in / out:
z/o - Go to gene:
:_gene_(e.g.:TP53) - Go to a chromosome position:
:_chr_:_position_: (e.g.:1:2345)
Full key bindings and comparison with Vim.
# View BAM file aligned to the hg19 human reference genome
tgv sorted.bam -g hg19
# Start at a coordinate
tgv sorted.bam -r 12:25398142 -g hg19
# View a indexed remote BAM, starting at TP53, using the hg38 reference genome
tgv s3://my-bucket/sorted.bam -r TP53
# Use --no-reference for non-human alignments
# (Sequence / feature display not supported yet)
tgv non_human.bam -r 1:123 --no-reference- BAM (index and sorted).
.baifile is needed.- Local, AWS, Google Cloud, or HTTP/HTTPS
- Local: place the
.baifile in the same directory; or specify the index file with-i. s3: set credentials in environmental variables. See: https://www.htslib.org/doc/htslib-s3-plugin.htmlgss: TODO not tested. Please provide feedback if it works!- Note that the custom
baipath (-i) is not supported for remote use for due to rust-htslib API limitation.
See ROADMAP.md for future plans.
Contribution is welcome. See CONTRIBUTE.md. Please join the Discord to discuss ideas!
-
How to quit TGV?
Just like vim :) PressEscto ensure you're in normal mode, then type:qand press Enter. -
Where are the reference genome data from?
- Sequences: UCSC Genome Browser API
- Annotation: UCSC MariaDB,
hg19/hg38, tablencbiRefSeqSelect(same as IGV)