.. include:: global.txt ============ Installation ============ Instructions for installing BiBench and its dependencies. BiBench is written for Python 2. It has been tested with both Python 2.6 and 2.7. ---------------------- Installation Procedure ---------------------- ++++++++++++++++++++++++++++++++ Automatic Installation with pip ++++++++++++++++++++++++++++++++ `pip `_ and `virtualenv `_ are currently the best way to install and manage Python packages. This method is also recommended because pip should automatically install BiBench's dependencies. (Note: One of BiBench's dependencies is rpy2, which requires that `R `_ be installed. R must have been built as a library. i.e., configured with ``--enable-R-shlib``, and libR.so must be available in LD_LIBRARY_PATH. For more information, see the `rpy FAQ `_). If you want pip to install BiBench without installing dependencies, use ``pip install --no-deps`` in the following steps. If it is not installed, install pip. If necessary, you can use pip to install virtualenv and virtualenvwrapper:: pip install virtualenv virtualenvwrapper To use virtualenvwrapper you must source virtualenvwrapper.sh, so that its commands are available in Bash. One option is to add the following to your .bashrc:: source `which virtualenvwrapper.sh` To create a new virtual environment called bibench_env and install BiBench and its dependencies to it: .. parsed-literal:: mkvirtualenv --no-site-packages bibench_env pip install |downloadurl| Pip can also install from a local package: .. parsed-literal:: wget |downloadurl| pip install BiBench-0.2.tar.gz BiBench is now installed and ready to go. The BiBench package is now installed into its own virtual environment, ``bibench_env``, which is an isolated Python environment. So before using BiBench you must switch to that environment:: workon bibench_env When you are done working in that environment, simply run the deactivate command:: deactivate +++++++++++++++++++ Manual installation +++++++++++++++++++ It is possible to manually install BiBench. In this case, all of BiBench's Python dependencies must be installed seperately. BiBench is packaged using `distutils `_. To install BiBench manually, simply download it, unpack it, and run the distutils setup script (depending on your Python setup, you may need to be root for this step): .. parsed-literal:: wget |downloadurl| tar xzf BiBench-0.2.tar.gz cd BiBench-0.2 python setup.py install +++++++++++++++++++++++++++ Building the documentation +++++++++++++++++++++++++++ This documentation may be compiled into a number of formats, using sphinx. To generate html:: make html For a list of all possible targets, run:: make help ------------ Dependencies ------------ The BiBench package is now installed, but most of its functionality will not be available until extra dependencies are available. In particular, BiBench does not provide implementations for biclustering algorithms; they must be installed seperately. +++++++++++++++++++ Python Dependencies +++++++++++++++++++ * `NumPy `_ * `rpy2 `_ * `decorator `_ * `nose `_ (optional: for running unit tests) * `sphinx `_ (optional: to make the documentation) If you install BiBench using pip, you should not need to install these packages manually; pip should automatically handle dependencies. If you chose not to install BiBench's dependencies before, you can install them with pip:: pip install numpy rpy2 decorator To install optional dependencies simply run:: pip install nose sphinx ++++++++++++++ R Dependencies ++++++++++++++ Much of BiBench's functionality depends on `R `_. Some algorithms that BiBench supports are available as packages for R; BiBench also relies on R for some visualization methods and other functionality. To communicate with R, the Python package rpy2 must be installed. rpy2 requires that R be compiled as a shared library using the configure option ``--enable-R-shlib``. Also libR.so must be available in LD_LIBRARY_PATH. For more information, see the `rpy FAQ `_. Assuming that R is installed, entering the following commands **in R** should install all of BiBench's R dependencies:: install.packages(c('biclust', 'isa2', 'MASS')) source("http://bioconductor.org/biocLite.R") biocLite() biocLite(c('fabia', 'GEOquery', 'GEOmetadb', 'GOstats', 'GO.db', 'multtest', 'pcaMethods')) The the rest of this section provides links to those dependencies. The following may be installed with the R command ``install.packages()``: * `biclust `_ * `isa2 `_ * `MASS `_ The rest of the packages require `Bioconductor `_. Here are the `installation directions `_ for Bioconductor and its packages. * `fabia `_ For downloading GDS data: * `GEOquery `_ * `GEOmetadb `_ For `Gene Ontology `_ enrichment analysis: * `GOstats `_ * `GO.db `_ * `multtest `_ * The correct `AnnotationData `_ package for your organism. For missing data imputation: * `pcaMethods `_ ++++++++++++++++++++++++++++ Other Algorithm Dependencies ++++++++++++++++++++++++++++ These algorithms are not available for R or Python. They must be manually built and installed, and their binaries must be available on the PATH, in order for the appropriate module in ``bibench.algorithms`` to work. * `BBC `_ * `COALESCE `_ (as part of the Sleipnir software) * `CPB `_ * `OPSM `_ (modified for command-line use from `BicAT `_) * `QUBIC `_