(define-module (gn packages statistics) #:use-module ((guix licenses) #:prefix license:) #:use-module (guix packages) #:use-module (guix utils) #:use-module (guix download) #:use-module (guix git-download) #:use-module (guix build-system python) #:use-module (guix build-system r) #:use-module (gnu packages) #:use-module (gnu packages bioinformatics) #:use-module (gnu packages cran) #:use-module (gnu packages gcc) #:use-module (gnu packages python) #:use-module (gnu packages python-science) #:use-module (gnu packages python-xyz) #:use-module (gnu packages statistics) #:use-module (gnu packages cran) ;; for python-rpy2 and dependencies #:use-module (gnu packages python-build) #:use-module (guix build-system pyproject); python-rpy2-rinterface #:use-module (gnu packages libffi); python-rpy2-rinterface #:use-module (gnu packages check); python-rpy2-rinterface #:use-module (gnu packages compression); python-rpy2-rinterface #:use-module (gnu packages icu4c); python-rpy2-rinterface #:use-module (gnu packages time); python-rpy2-robjects #:use-module (guix gexp)) (define-public r-graphics (package (name "r-graphics") (version "2.0-13") (source (origin (method url-fetch) (uri (cran-uri "RGraphics" version)) (sha256 (base32 "10c6wiqh074bmbg2gwdscwp5kj8afs152ipv0byyqw5n2r8fw0w1")))) (properties `((upstream-name . "RGraphics"))) (build-system r-build-system) (propagated-inputs `(;; ("r-datasets" ,r-datasets) ("r-ggplot2" ,r-ggplot2) ;; ("r-graphics" ,r-graphics) ;; ("r-grdevices" ,r-grdevices) ;; ("r-grid" ,r-grid) ("r-lattice" ,r-lattice) ;; ("r-methods" ,r-methods) ;; ("r-stats" ,r-stats) )) (home-page "http://www.stat.auckland.ac.nz/~paul/RG2e/index.html") (synopsis "Data and Functions from the Book R Graphics, Second Edition") (description "Data and Functions from the book R Graphics, Second Edition. There is a function to produce each figure in the book, plus several functions, classes, and methods defined in Chapter 8.") (license license:gpl2+))) (define-public r-ctl ; guix: ready (package (name "r-ctl") (version "1.0.0-7") (source (origin (method url-fetch) (uri (cran-uri "ctl" version)) (sha256 (base32 "1a01rha6sgv8zmcfjb1c438s9d9bjzdjf2pmyml1m5jmz93q70ds")))) (build-system r-build-system) (inputs `( ("r-qtl" ,r-qtl) ("r-mass" ,r-mass) )) (home-page "https://github.com/DannyArends/CTLmapping") (synopsis "R package for analysis of genetical genomic data to identify genetic loci associated with correlation changes in quantitative traits (CTL)") (description "Analysis of experimental crosses to identify genetic markers associated with correlation changes in quantitative traits (CTL). The additional correlation information obtained can be combined with QTL information to perform de novo reconstruction of interaction networks.") (license license:gpl3))) (define-public python-rpy2-rinterface (package (name "python-rpy2-rinterface") (version "3.6.2") (source (origin (method url-fetch) (uri (pypi-uri "rpy2_rinterface" version)) (sha256 (base32 "1hjnc4143dvcrp9m4vnxm4fs2ahiagp5lklsqp1nki341kh0samn")))) (build-system pyproject-build-system) (propagated-inputs (list python-cffi python-packaging ;;python-backports-zoneinfo ; needed for python_version<3.9 r-minimal)) (native-inputs (list zlib icu4c libdeflate python-cffi python-coverage python-packaging python-pytest python-pytest-cov python-setuptools python-wheel r-survival)) (home-page "https://rpy2.github.io/") (synopsis "Low-level interface from Python to the R") (description "Low-level interface for rpy2. rpy2 is an interface to R running embedded in a Python process.") (license license:gpl2))) (define-public python-rpy2-robjects (package (name "python-rpy2-robjects") (version "3.6.1") (source (origin (method url-fetch) (uri (pypi-uri "rpy2_robjects" version)) (sha256 (base32 "0yn4nq26na9hzlm08vsxr050ls5nmngpyma49fpfwc9mhxc7njlk")))) (build-system pyproject-build-system) (arguments (list #:phases #~(modify-phases %standard-phases (replace 'check (lambda* (#:key tests? #:allow-other-keys) (when tests? ;; test_rmagic.py fails with pytest 9: marks on fixtures ;; are no longer allowed. (invoke "pytest" "-vv" "--ignore=src/rpy2/ipython/tests/test_rmagic.py"))))))) (propagated-inputs (list python-jinja2 python-packaging python-rpy2-rinterface ;;python-backports-zoneinfo; needed for python_version<3.9 python-tzlocal)) (native-inputs (list python-coverage python-ipython python-numpy python-packaging python-pandas python-pytest python-pytest-cov python-setuptools python-wheel)) (home-page #f) (synopsis "Python interface to the R language (embedded R)") (description "Python interface to the R language (embedded R).") (license #f))) (define-public python-rpy2-patched ;; TODO: Delete this after python-rpy2 is fixed upstream. (package (inherit python-rpy2) (name "python-rpy2") (version "3.6.2") (source (origin (method url-fetch) (uri (pypi-uri "rpy2" version)) (sha256 (base32 "1l3paflfc2wczjms9ghaklg4bxg0c2cqh4anvlskpl4id9vsakhp")))) (propagated-inputs (modify-inputs (package-propagated-inputs python-rpy2) (prepend r-minimal) (prepend python-rpy2-rinterface) (prepend python-rpy2-robjects))) (arguments (list #:phases #~(modify-phases %standard-phases (add-before 'build 'fix-license-metadata (lambda* _ ;; Remove one field (substitute* "./pyproject.toml" (("license = \"GPL-2.0-or-later\"\n") "") ;; update remaining field to acceptable PEP 621 format (("^license-files = .*$") "license = {file = \"LICENSE\"}\n")))) (delete 'check)))))) (define-public r-thor (package (name "r-thor") (version "1.2.0") (source (origin (method url-fetch) (uri (cran-uri "thor" version)) (sha256 (base32 "1g9204n6khm1k9ifwlmhbycfp996k5c2zpcmk2aqd95iqafpaw4g")))) (build-system r-build-system) (propagated-inputs `(("r-r6" ,r-r6) ("r-storr" ,r-storr))) (native-inputs (list r-testthat r-knitr)) (home-page "https://github.com/richfitz/thor") (synopsis "R binding for the ‘Lightning’ database (LMDB) ") (description "This package is an R interface to LMDB. LMDB is an embedded transactional key-value store and this package provides R mappings to it. It wraps the entire LMDB interface, except for support for duplicated keys.") (license license:openldap2.8)))