Skip to content

v0.7.0

Latest

Choose a tag to compare

@Zethson Zethson released this 25 Nov 10:24
Immutable release. Only release title and notes can be modified.
8137f7f

Highlights

  • DeseqStats takes a reduced design and then tests it against the design of the DeseqDataSet with a likelihood ratio test, as DESeq(test="LRT", reduced=...) does in DESeq2 (#542).
  • fit_type="local" fits DESeq2's local dispersion trend, for both deseq2() and vst(), without depending on locfit (#527).
  • DeseqDataSet.plot_rle draws relative log expression plots (#545).
  • lfc_shrink() without coeff shrinks the coefficient of the contrast again (#543).
  • Results are much closer to DESeq2 when a coefficient diverges, for instance for a level with a single sample and zero counts (#538).
    On the dataset of #217, PyDESeq2 finds 1817 of DESeq2's 1944 genes at padj < 0.05, against 921 before.
  • LFC shrinkage stops at the MAP for very small dispersions and narrow priors (#547), and its gradient and Hessian no longer overflow (#529).
  • Iterative size factors are fitted with L-BFGS-B, so datasets with a zero in every gene no longer look like they hang: 200 samples by 2000 genes take 1.8 s instead of 324 s (#528).
  • DeseqDataSet warns when a column of the design matrix is badly scaled (#530), rejects duplicated gene names (#526), and checks the index of a design matrix against the sample names (#536).
  • import pydeseq2.grid_search works as the first import (#525), and joblib backends other than loky work (#546).
  • deseq2_norm_transform leaves zero counts of new samples, such as the counts passed to vst_transform, out of the size factor median (#535), and trimmed_variance is correct along axis=1 (#534).
  • The documentation has a new tutorial on the pasilla dataset from the DESeq2 vignette (#540) and explains how to set the reference level of a factor (#544).

Changed behaviour

  • p-values, LFCs and Cook's filtering change for genes with diverging coefficients (#538).
    Outliers with 3 or more samples of higher counts are kept only for a single two-level factor, as in DESeq2.
  • Shrunk LFCs change for genes whose shrinkage fit used to stop before the MAP (#547).
  • Iterative size factors differ from the previous ones by at most 0.1% (#528).
  • Duplicated gene names raise a ValueError when building a DeseqDataSet instead of failing later in deseq2() (#526).
  • lfc_shrink() without coeff raises a ValueError when the contrast involves several coefficients or has a weight other than 1 on its coefficient (#543, #544).
    Set the reference level in the design instead, for example with C(condition, contr.treatment(base="B")).
  • deseq2_norm_transform gives a NaN size factor to a sample with no positive count or a NaN count among the fitted genes (#535).

What's Changed

  • fix: import pydeseq2.grid_search without importing another module first by @Zethson in #525
  • fix: reject duplicated gene names when building a DeseqDataSet by @Zethson in #526
  • feat: add the local dispersion trend fit by @Zethson in #527
  • perf: fit iterative size factors with L-BFGS-B and an analytic gradient by @Zethson in #528
  • fix: compute the shrinkage gradient and Hessian without overflow by @Zethson in #529
  • feat: warn when the design matrix has badly scaled columns by @Zethson in #530
  • fix: validate the design matrix index against the sample names by @Zethson in #536
  • fix: match DESeq2's GLM fit and Cook's filter for diverging coefficients by @Zethson in #538
  • chore: use the scverse pull request template from pertpy by @Zethson in #539
  • docs: drop parameter defaults from docstrings by @Zethson in #541
  • docs: add a tutorial on the pasilla dataset by @Zethson in #540
  • feat: shrink the coefficient of the contrast when lfc_shrink has no coeff by @Zethson in #543
  • feat: add the likelihood ratio test by @Zethson in #542
  • docs: explain how to set the reference level of a factor by @Zethson in #544
  • feat: add relative log expression plots by @Zethson in #545
  • fix: support joblib backends other than loky by @Zethson in #546
  • fix: stop the shrinkage fit at the MAP by @Zethson in #547
  • fix: centre trimmed_variance along the requested axis by @Namra-5 in #534
  • fix: ignore zero counts in size factor median of deseq2_norm_transform by @Namra-5 in #535
  • Chore(deps): bump the pre-commit group with 2 updates by @dependabot[bot] in #548

New Contributors

Full Changelog: v0.6.0...v0.7.0