pyranges
GenomicRanges for Python.
Decision gist · record as of 2026-08-14
Yes. PyRanges is actively maintained, has no known vulnerabilities, installs with low friction, and is widely used in bioinformatics. The MIT license poses no restrictions. Install it if you work with genomic intervals or annotations in Python.AI-flagged interpretation of the facts on this page — verify before relying
Before you install
- Low install friction with a pure Python wheel distribution.
- Active maintenance with recent commits (last commit 2026-04-23) and steady releases; 493 repository stars indicate established use in the bioinformatics community.
License · maintenance · safety
MIT (permissive) — MIT license is permissive, allowing use in commercial and proprietary projects with minimal restrictions beyond attribution.
last release 2025-03-14 (518 days) · last repo commit 2026-04-23 · 493 stars
0 known vulnerabilities (OSV.dev, 2026-08-14) · 88,207 downloads/mo, #13,743 on PyPI
Alternatives
Verify before relying
import pyranges as pr
import pandas as pd
# Create a PyRanges object from a DataFrame
df = pd.DataFrame({'Chromosome': ['chr1'], 'Start': [0], 'End': [1]})
gr = pr.PyRanges(df)
print(gr)- Whether the package requires specific versions of pandas, ncls, or other runtime dependencies beyond what pip resolves automatically
- Performance characteristics and scalability limits for very large genomic datasets
What it is and what it does
PyRanges is a Python library for working with genomic intervals—discrete regions of DNA sequences like genes, regulatory features, or sequencing reads. It wraps pandas DataFrames to provide a genomics-specific interface optimized for fast querying and manipulation of these intervals, making it easier to perform common bioinformatics tasks like overlap detection, merging, and filtering without writing low-level code.
The library is built on top of pandas and integrates with the broader Python data science ecosystem, so you can chain operations with a terse syntax and leverage existing pandas and NumPy tools on the results. It depends on ncls for interval indexing, sorted_nearest for nearest-neighbor queries, tabulate for display, and natsort for natural sorting of genomic coordinates.
Use it for
- Find overlapping genomic features (e.g., which genes overlap with a set of ChIP-seq peaks)
- Merge or subtract genomic intervals to build consensus annotations or mask regions
- Query and filter large genomic datasets by chromosome, position, or feature type
- Perform nearest-neighbor searches to find the closest gene to a variant position
Worth the install?
AI-flagged interpretation of the facts on this page. Verify before relying on it.
Yes.
PyRanges is actively maintained, has no known vulnerabilities, installs with low friction, and is widely used in bioinformatics. The MIT license poses no restrictions. Install it if you work with genomic intervals or annotations in Python.
Install
pyranges on PyPI
Before you install
Low install friction with a pure Python wheel distribution. Active maintenance with recent commits (last commit 2026-04-23) and steady releases; 493 repository stars indicate established use in the bioinformatics community.
License in practice
MIT license is permissive, allowing use in commercial and proprietary projects with minimal restrictions beyond attribution.
Quickstart
import pyranges as pr
import pandas as pd
# Create a PyRanges object from a DataFrame
df = pd.DataFrame({'Chromosome': ['chr1'], 'Start': [0], 'End': [1]})
gr = pr.PyRanges(df)
print(gr)
Verify before relying
- Whether the package requires specific versions of pandas, ncls, or other runtime dependencies beyond what pip resolves automatically
- Performance characteristics and scalability limits for very large genomic datasets
Package facts
| License | MIT permissive |
| Python support | Not specified |
| Install friction | Low. Pure-Python wheel |
| Runtime dependencies | 5 packagespandasnclstabulatesorted_nearestnatsort |
| Maintenance | Actively maintained 518 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 88,207 / month, #13,743 on PyPI 30-day window, as of 2026-08-14 |
| Known vulnerabilities | None known OSV.dev, checked 2026-08-14 |
| Classifiers | Development Status :: 4 - BetaEnvironment :: Other EnvironmentIntended Audience :: DevelopersIntended Audience :: Science/ResearchLicense :: OSI Approved :: MIT LicenseOperating System :: MacOS :: MacOS XOperating System :: POSIX :: LinuxProgramming Language :: Python :: 3Topic :: Scientific/Engineering |
Evidence: pyranges-0.1.4-py3-none-any.whl
Tags
Let your AI agent find packages like this
Example. Real query, live index.
You found this page by searching. An agent finds it by wishing: SkillFed indexes 14,416 PyPI packages by what they can do, searchable in plain language.
wish › “genomic intervals manipulation”
- pyrangesPyRanges provides efficient querying and manipulation of genomic…
- nclsNCLS provides a fast interval overlap query data structure…
- bx-pythonbx-python provides Python classes and utilities for reading,…
Give your agent the search over MCP, or paste the wish link into any chat.
More Scientific/Engineering packages
NumPy provides an N-dimensional array object and a comprehensive suite of mathematical, linear algebra, Fourier transform, and random number functions for scientific computing in Python.
pandas provides fast, flexible data structures (Series and DataFrame) for loading, cleaning, transforming, and analyzing labeled or relational data in Python.
scipy provides numerical algorithms for mathematics, science, and engineering—including optimization, integration, linear algebra, Fourier transforms, signal and image processing, and ODE solvers—built on numpy arrays.
scikit-learn provides a comprehensive Python library for supervised and unsupervised machine learning, including classification, regression, clustering, dimensionality reduction, and model evaluation tools built on NumPy and SciPy.
Install it if you need to train, evaluate, or deploy supervised or unsupervised learning models.
dill extends Python's pickle module to serialize and deserialize a much wider range of Python objects, including functions, lambdas, classes, and interpreter sessions, to byte streams for storage or network transmission.
Multiprocess is an enhanced fork of Python's standard multiprocessing library that uses dill for better serialization, allowing you to spawn processes with a threading-like API and share complex objects between them.
Install it if you use multiprocessing and encounter pickle serialization limits with lambdas or complex objects.
See also pybedtools · ncls · cg · gtfparse · pyensembl · refgenie · bx-python · gseapy · deepbiop · pyBigWig