$npx skillfedfor your agent

pybedtools

Wrapper around BEDTools for bioinformatics work

With conditionsPyPI Python ModulesReleased Mar 2025109.6K downloads / moMITSource build

Decision gist · record as of 2026-08-14

sdist only — pybedtools-0.12.0.tar.gz · builds from source
v0.12.0 · released 2025-03-16 · 3 runtime deps: numpy, pysam, pandas

Yes, if you have BEDTools already installed and work regularly with genomic intervals in Python. The high install friction and aging maintenance status (516 days since release) are real drawbacks, but the package is stable, permissively licensed, and solves a genuine problem for bioinformaticians. Not worth installing if you lack BEDTools or only occasionally need interval operations.AI-flagged interpretation of the facts on this page — verify before relying

Before you install

  • BEDTools must be installed and available on the system as a compiled binary before pybedtools can wrap it.
  • High install friction: requires BEDTools as a compiled system dependency.
  • Package is aging (516 days since last release) but repo is not archived with recent activity on 2025-03-16.

License · maintenance · safety

MIT (permissive) — MIT license is permissive; you can use, modify, and distribute pybedtools with minimal restrictions, suitable for academic and commercial projects.

last release 2025-03-16 (516 days) · last repo commit 2025-03-16 · 330 stars

0 known vulnerabilities (OSV.dev, 2026-08-14) · 109,608 downloads/mo, #12,506 on PyPI

Verify before relying

from pybedtools import BedTool

snps = BedTool('snps.bed.gz')
genes = BedTool('hg19.gff')
intergenic_snps = snps.subtract(genes)
nearby = genes.closest(intergenic_snps, d=True, stream=True)
for gene in nearby:
    if int(gene[-1]) < 5000:
        print(gene.name)
  • Whether BEDTools must be pre-installed on the system or if pybedtools handles installation automatically
  • Compatibility with Python versions beyond 3.8 (classifiers list 3.6, 3.7, 3.8 but requires_python is unspecified)
Same gist for agents: .md · .json

What it is and what it does

pybedtools is a Python wrapper around the BEDTools suite, a widely-used toolkit for genomic interval manipulation. It lets you perform operations like subtract, intersect, and closest on genomic features directly from Python code, rather than chaining shell commands. The package supports all BEDTools-compatible file formats (BED, GFF, and others, including gzipped variants) and can stream results like Unix pipes, making it memory-efficient for large genomic datasets.

The package depends on numpy, pysam, and pandas for data handling. It's designed for bioinformaticians and computational biologists who want to avoid writing complex bash scripts for routine genomic analyses. The main trade-off is the high install friction: BEDTools itself must be available on your system as a compiled binary before pybedtools can wrap it.

Use it for

  • Find genes within a specific distance of intergenic variants by combining subtract and closest operations on BED/GFF files.
  • Filter genomic features by intersection with regulatory regions or exclusion zones using subtract and intersect.
  • Stream large genomic datasets through multiple operations without materializing intermediate results to disk.
  • Iterate over genomic features and access their attributes (name, coordinates, scores) programmatically in Python loops.
  • Automate repetitive genomic interval analyses that would otherwise require shell script pipelines.

Worth the install?

AI-flagged interpretation of the facts on this page. Verify before relying on it.

With conditions

Yes, if you have BEDTools already installed and work regularly with genomic intervals in Python.

The high install friction and aging maintenance status (516 days since release) are real drawbacks, but the package is stable, permissively licensed, and solves a genuine problem for bioinformaticians. Not worth installing if you lack BEDTools or only occasionally need interval operations.

Install

pybedtools on PyPI

Before you install

High install friction: requires BEDTools as a compiled system dependency. Package is aging (516 days since last release) but repo is not archived with recent activity on 2025-03-16.

BEDTools must be installed and available on the system as a compiled binary before pybedtools can wrap it.

License in practice

MIT license is permissive; you can use, modify, and distribute pybedtools with minimal restrictions, suitable for academic and commercial projects.

Quickstart

from pybedtools import BedTool

snps = BedTool('snps.bed.gz')
genes = BedTool('hg19.gff')
intergenic_snps = snps.subtract(genes)
nearby = genes.closest(intergenic_snps, d=True, stream=True)
for gene in nearby:
    if int(gene[-1]) < 5000:
        print(gene.name)

Verify before relying

  • Whether BEDTools must be pre-installed on the system or if pybedtools handles installation automatically
  • Compatibility with Python versions beyond 3.8 (classifiers list 3.6, 3.7, 3.8 but requires_python is unspecified)

Package facts

LicenseMIT permissive
Python supportNot specified
Install frictionHigh. Source build required
Runtime dependencies
3 packages
numpypysampandas
MaintenanceAging 516 days since the last release
Last repo commit
First released
Downloads109,608 / month, #12,506 on PyPI 30-day window, as of 2026-08-14
Known vulnerabilitiesNone known OSV.dev, checked 2026-08-14
Classifiers
Development Status :: 5 - Production/StableIntended Audience :: Science/ResearchLicense :: OSI Approved :: MIT LicenseProgramming Language :: PythonProgramming Language :: Python :: 3Programming Language :: Python :: 3.6Programming Language :: Python :: 3.7Programming Language :: Python :: 3.8Topic :: Scientific/Engineering :: Bio-InformaticsTopic :: Software Development :: Libraries :: Python Modules

Evidence: pybedtools-0.12.0.tar.gz

Tags

Capabilities
genomic interval manipulation pythonbedtools python wrappergenome algebra operationsbioinformatics interval operationsbed file processing pythongenomic feature comparisonintergenic region analysis
Topics
bioinformaticsgenomicsbedtools-wrapper

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 › “bedtools python wrapper”

  • pybedtoolsWraps the BEDTools suite to perform genomic interval operations…
  • dbs3-pycurlProvides a Python client wrapper around pycurl for making HTTP…
  • pgdbWraps PostgreSQL connections to return query results as dictionaries…

Give your agent the search over MCP, or paste the wish link into any chat.

More Python Modules packages

idna Worth it
PyPI · Python Modules · released Jun 2026

Converts domain names between Unicode and ASCII-compatible encoding (Punycode) according to IDNA 2008 and Unicode Technical Standard 46, with security validation and broader script coverage than the standard library.

Install it if you work with internationalized domain names, need to validate domains, or use HTTP clients that depend on it transitively.

BSD-3-Clausepure Python · 3.9+
1.8Bdownloads / mo
setuptools Worth it
PyPI · Python Modules · released Aug 2026

Setuptools is a Python build backend and package management tool that handles building, distributing, and installing Python packages, including support for C/C++ extension modules.

MITpure Python · 3.10+
1.6Bdownloads / mo
PyYAML Worth it
PyPI · Python Modules · released Sep 2025

PyYAML parses and emits YAML 1.1 data format, enabling serialization and deserialization of configuration files and Python objects to and from human-readable YAML text.

MITcompiled wheel · 3.8+
1.2Bdownloads / mo
pydantic Worth it
PyPI · Python Modules · released May 2026

Pydantic validates Python data structures against type hints, coercing and checking input at runtime to ensure it matches a declared schema.

MITpure Python · 3.9+
1.1Bdownloads / mo
annotated-types Worth it
PyPI · Python Modules · released Jul 2026

Provides reusable metadata objects for use with PEP-593 `typing.Annotated` to express common constraints like bounds, collection sizes, and predicates on types.

Install it if you use or build libraries that need to express type constraints in a standardized, inspectable way—or if you want to annotate your own types with…

MITpure Python · 3.10+
871.3Mdownloads / mo
typing-inspection Worth it
PyPI · Python Modules · released Aug 2026

Provides runtime tools to inspect and introspect Python type annotations, enabling programmatic examination of type hints at execution time.

MITpure Python · 3.10+
783.0Mdownloads / mo

See also pyranges · pybigtools · gtfparse · pysam · pyensembl · bx-python · cg · bio · deepbiop · ncls