Metadata-Version: 2.4
Name: tradeSeq-python
Version: 1.13.12
Summary: Python port of the R tradeSeq package (tracks statOmics/tradeSeq 1.13.12 @ 02a9050) — trajectory-based differential expression analysis (NB-GAM)
Author: tradeSeq port
License-Expression: Artistic-2.0
License-File: LICENSE
Requires-Python: >=3.10
Requires-Dist: anndata>=0.10
Requires-Dist: ggplot2-python>=4
Requires-Dist: joblib>=1.3
Requires-Dist: numpy>=1.24
Requires-Dist: pandas>=2.0
Requires-Dist: patchwork-python>=1.3
Requires-Dist: pheatmap-python>=1.0
Requires-Dist: scikit-learn>=1.3
Requires-Dist: scipy>=1.11
Requires-Dist: statsmodels>=0.14
Requires-Dist: tqdm>=4.0
Provides-Extra: dev
Requires-Dist: pytest; extra == 'dev'
Requires-Dist: pytest-cov; extra == 'dev'
Requires-Dist: ruff; extra == 'dev'
Provides-Extra: docs
Requires-Dist: mkdocs; extra == 'docs'
Requires-Dist: mkdocs-jupyter; extra == 'docs'
Requires-Dist: mkdocs-material; extra == 'docs'
Requires-Dist: mkdocstrings[python]; extra == 'docs'
Description-Content-Type: text/markdown

# tradeSeq-python

[![PyPI](https://img.shields.io/pypi/v/tradeSeq-python)](https://pypi.org/project/tradeSeq-python/)

Python [**tradeSeq**](https://github.com/statOmics/tradeSeq) package — trajectory-based differential expression analysis with negative-binomial generalized additive models (NB-GAM).


## Installation

```bash
pip install tradeSeq-python                # from PyPI
```

## Quickstart

```python
import tradeseq as ts

adata = ts.load_paul15()                              # AnnData (2660 × 240)

ts.fit_gam(adata, n_knots=6)                          # NB-GAM per gene

assoc = ts.association_test(adata)                    # expression vs pseudotime
start = ts.start_vs_end_test(adata)                   # progenitor markers
diff  = ts.diff_end_test(adata)                       # between-lineage endpoints
patt  = ts.pattern_test(adata)                        # between-lineage patterns
early = ts.early_de_test(adata, knots=(1, 2))         # early drivers

ts.plot_smoothers(adata, gene=start['waldStat'].idxmax())
ts.plot_gene_count(adata, gene=start['waldStat'].idxmax())
```

Choose the number of knots with `evaluate_k` / `evaluate_k2` and `plot_evaluatek_results`. `evaluate_k2` is a speed-up version of the original `evaluate_k`.

## Tutorials

Runnable notebooks that reproduce the R tradeSeq vignettes live under [`tutorials/`](tutorials/):

| Notebook | Coverage |
|---|---|
| `tradeSeq.ipynb` | Full Wald battery on the Paul-2015 myeloid trajectory — mirrors `vignettes/tradeSeq.Rmd` |
| `fitGAM.ipynb`   | Model-fitting options — covariates, parallelism, list-mode output, convergence diagnostics |

