Pygenesig, a framework to generate and validate tissue-specific gene signatures.

Build Status Documentation Status PyPI The uncompromising python formatter

Gene signatures are sets of genes derived from gene expression data, which identify a certain tissue, cell type, pathway, etc. Pygenesig provides a framework to create and validate such signatures. The package is easily extensible to add new methods for signature creation and testing.

Getting started

Please refer to the documentation, in particular the sections

If you want to implement own methods for creating and testing signatures, please take a look at the

Installation

You need to have Python 3.7 or newer installed on your system. Some methods for creating or testing signatures additionally require R. If you don’t have Python installed, we recommend installing Miniforge.

There are several alternative options to install pygenesig:

  1. Install pygenesig in a self-contained conda environment:

    This is the most reliable option to make both R and Python work. Make sure you have the `conda-forge` and the `bioconda` channels set-up with the correct priorities as described in the Bioconda documentation.

    # use `mamba` instead of `conda` for more speed
    mamba create -n pygenesig python=3.8 pip bioconductor-edger bioconductor-bioqc
    conda activate pygenesig
    pip install pygenesig
    
  2. Install pygenesig via pip and R packages manually

    pip install pygenesig
    

    Then, in R:

    install.packages("BiocManager")
    BiocManager::install(c("edgeR", "BioQC"))
    

    Usually, if R is in your PATH, rpy2 automatically detects your R installation. If you get an error message while importing pygensig, try setting the R_HOME environment variable before importing pygenesig:

    import os
    os.environ["R_HOME"] = "/usr/lib/R"
    import pygenesig
    
  3. Install the latest development version from GitHub:

    pip install git+https://github.com/grst/pygenesig.git@master
    

    You’ll need to separately install R packages as described above.

Release notes

See the release section.

Contact

Please use the issue tracker.