diff options
author | Ricardo Wurmus <rekado@elephly.net> | 2024-05-02 16:37:03 +0200 |
---|---|---|
committer | Ricardo Wurmus <rekado@elephly.net> | 2024-05-05 22:38:17 +0200 |
commit | 93a397f8b7e98f03b1a5d5c31b3a6bb685f5b055 (patch) | |
tree | 1f16f6d1f1c2dcd171f8c8ad68a7c5fd86185ff5 | |
parent | 453b7a267b4b0e76bc09e7ad00275a9e0573f95c (diff) |
gnu: tadbit: Patch for compatibility with latest scipy.
* gnu/packages/bioinformatics.scm (tadbit)[arguments]: Add phase
'scipy-compatibility.
Change-Id: Ib25b9cde75f0505c347c4ff470e61f06fb162839
-rw-r--r-- | gnu/packages/bioinformatics.scm | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/gnu/packages/bioinformatics.scm b/gnu/packages/bioinformatics.scm index 0f9b5d0695..05d529afa6 100644 --- a/gnu/packages/bioinformatics.scm +++ b/gnu/packages/bioinformatics.scm @@ -14137,6 +14137,18 @@ applications for tackling some common problems in a user-friendly way.") (list #:phases #~(modify-phases %standard-phases + ;; Scipy 1.12 no longer has binom_test or polyfit + (add-after 'unpack 'scipy-compatibility + (lambda _ + (substitute* '("_pytadbit/modelling/imp_modelling.py" + "_pytadbit/modelling/restraints.py") + (("from scipy .*import polyfit") + "from numpy import polyfit")) + (substitute* "_pytadbit/mapping/restriction_enzymes.py" + (("from scipy.stats import binom_test") + "from scipy.stats import binomtest") + (("binom_test\\(pats[k]['count'], nreads, 0.25\\*\\*len\\(k\\), alternative='greater'\\)") + "binomtest(pats[k]['count'], nreads, 0.25**len(k), alternative='greater').pval")))) (add-after 'unpack 'fix-problems-with-setup.py (lambda _ (substitute* "src/test/Makefile" |