Metadata-Version: 2.5
Name: de_toolkit
Version: 1.0.0
Summary: Suite of tools for working with count data
Project-URL: Homepage, https://github.com/BU-Neuromics/de_toolkit
Project-URL: Repository, https://github.com/BU-Neuromics/de_toolkit
Project-URL: Documentation, https://bu-neuromics.github.io/de_toolkit/
Project-URL: Changelog, https://github.com/BU-Neuromics/de_toolkit/blob/main/CHANGELOG
Project-URL: Issues, https://github.com/BU-Neuromics/de_toolkit/issues
Author-email: Adam Labadorf and the BU Bioinformatics Hub Team <labadorf@bu.edu>
License-Expression: MIT
License-File: LICENSE
Keywords: NGS,bioinformatics,biology,sequencing
Classifier: Development Status :: 5 - Production/Stable
Classifier: Environment :: Console
Classifier: Intended Audience :: Science/Research
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: 3.13
Classifier: Topic :: Scientific/Engineering :: Bio-Informatics
Requires-Python: >=3.11
Requires-Dist: formulaic>=1.1
Requires-Dist: jinja2
Requires-Dist: matplotlib
Requires-Dist: numpy>=2
Requires-Dist: pandas>=3
Requires-Dist: ply
Requires-Dist: scikit-learn
Requires-Dist: scipy
Requires-Dist: terminaltables
Provides-Extra: test
Requires-Dist: pytest; extra == 'test'
Requires-Dist: pytest-cov; extra == 'test'
Requires-Dist: statsmodels>=0.14; extra == 'test'
Description-Content-Type: text/markdown

[![CI](https://github.com/BU-Neuromics/de_toolkit/actions/workflows/ci.yml/badge.svg)](https://github.com/BU-Neuromics/de_toolkit/actions/workflows/ci.yml)
[![docs](https://img.shields.io/badge/docs-latest-blue)](https://bu-neuromics.github.io/de_toolkit/)
[![License: MIT](https://img.shields.io/badge/License-MIT-blue)](https://github.com/BU-Neuromics/de_toolkit/blob/main/LICENSE)
[![PyPI](https://img.shields.io/pypi/v/de_toolkit)](https://pypi.org/project/de_toolkit/)

# Introduction

This is a collection of utilities to perform various operations on genomic
count datasets involving determining differential expression.

# Documentation

Documentation is at:

- [bu-neuromics.github.io/de_toolkit](https://bu-neuromics.github.io/de_toolkit/)

See a [live example report](https://bu-neuromics.github.io/de_toolkit/example/detk_report.html)
generated from the public [airway RNA-seq dataset](https://bu-neuromics.github.io/de_toolkit/example/)
— self-contained HTML produced by `detk-report generate`.

# Installing

## From pypi

```
pip install de_toolkit
```

## Installing R and packages

Certain functions in detk, particularly the `de`, `enrich`, and `transform`
modules, interface with R and Bioconductor packages. You must have a version of
R installed along with the following packages to use the corresponding
submodule functions:

  - [DESeq2](https://bioconductor.org/packages/release/bioc/html/DESeq2.html)
  - [fgsea](https://bioconductor.org/packages/release/bioc/html/fgsea.html)
  - [logistf](https://cran.r-project.org/web/packages/logistf/index.html)
  - [jsonlite](https://cran.r-project.org/web/packages/jsonlite/index.html),
    which every R-backed command uses to exchange data with R

The packages can be installed from within R with:

```r
install.packages("BiocManager")
BiocManager::install(c("DESeq2", "fgsea"))
install.packages(c("logistf", "jsonlite"))
```

# Development

detk requires Python 3.11 or newer. First fork and/or clone this repo:

```
git clone https://github.com/BU-Neuromics/de_toolkit.git
```

The project is managed with [uv](https://docs.astral.sh/uv/):

```
cd de_toolkit
uv sync        # create .venv with the package and dev tools
uv run pytest  # run the test suite
```

If you don't use uv, a plain virtualenv works too: `pip install -e '.[test]'`,
then `pytest`. Lint and format with `uv run ruff check .` and
`uv run ruff format .`; docs preview with `uv run --group docs mkdocs serve`.

Tests that require R (DESeq2, fgsea, logistf) are skipped automatically when R
is not available.

To add a command, a subcommand or an option, see
[docs/dev/cli.md](https://github.com/BU-Neuromics/de_toolkit/blob/main/docs/dev/cli.md): the parsers are argparse, and their help
is part of the 1.0 promise.

# Agent skills

detk ships an
[agent skill](https://github.com/BU-Neuromics/de_toolkit/tree/main/skills/detk)
that lets a coding agent (Claude Code, Codex, Cursor and others) run a detk
analysis from a counts matrix and sample table through filter, norm, de and
enrich to a detk report.
Install it into your project with:

```
npx skills add BU-Neuromics/de_toolkit
```

See [Agent skills](https://bu-neuromics.github.io/de_toolkit/agent-skills/)
in the documentation.
