PyRanges is a Python library specifically designed for efficient and intuitive manipulation of genomics data, particularly genomic intervals (like genes, genomic features, or reads). The library is optimized for fast querying and manipulation of genomic annotations.
"Finally ... This was what Python badly needed for years." - Heng Li
The pyranges documentation is centralized at https://pyranges.readthedocs.io/ Visit it to find installation instructions, API, tutorial, and how-to-pages.
- fast
- memory-efficient
- featureful
- pythonic/pandastic
- supports chaining with a terse syntax
- uses Pandas DataFrames, so the whole Python data science stack works on PyRanges.
Stovner EB, Sætrom P (2020) PyRanges: efficient comparison of genomic intervals in Python. Bioinformatics 36(3):918-919 http://dx.doi.org/10.1093/bioinformatics/btz615
- most importantly, cite pyranges if you use it. It is the main metric funding sources care about.
- use pyranges in Stack Overflow/biostars questions and answers
- star the repo (possibly important for github visibility and as a proxy for project popularity)
- if you are a business using pyranges, please give to one of the charities listed at https://www.givewell.org/