Skip to content

Installation

Eduard Kerkhoven edited this page Sep 25, 2024 · 37 revisions

Required software # Installation instructions # Optional software (Solvers | COBRA Toolbox) # Uninstall

Required software

  • A functional MATLAB installation (version 2016b or later).
  • Recommended: Gurobi as alternative solver.
  • Optional: COBRA Toolbox for more simulation functions.
  • Development: if new HMMs are to be trained from a KEGG FTP-dump on a Windows PC, it is required to have Windows Subsystem for Linux installed.

Installation instructions

Obtain RAVEN Toolbox

Use one of the three following ways to obtain RAVEN Toolbox: easy / medium / advanced.

Easy

  • Open Add-Ons Explorer in MATLAB: in the Home tab and the Environment section, click the Add-Ons icon.
  • Search for RAVEN Toolbox and click Add -> Add to MATLAB.
  • Follow the Install RAVEN in MATLAB instructions below.
    • If RAVEN commands are not recognized, you might need to enable it by running matlab.addons.enableAddon("RAVEN").

Upgrade RAVEN after Easy installation

  • In the Home tab, click on Help > Check for Updates.
  • Click on the Update button for RAVEN Toolbox.
  • If RAVEN Toolbox is not mentioned among the Updates, it might help to restart MATLAB.
  • Follow the Install RAVEN in MATLAB instructions below.

Medium

  • Download the latest release of the RAVEN Toolbox.
  • Extract the ZIP file to your favourite directory.
  • Follow the Install RAVEN in MATLAB instructions below.

Upgrade RAVEN after Medium installation

  • Close MATLAB.
  • First delete the complete RAVEN folder from your computer.
  • Optional: run pathtool to remove all mentions of the RAVEN folder and subfolders from the MATLAB path, and click Save. This prevents warning messages regarding non-existing paths when opening MATLAB anew.
  • Download the latest release of the RAVEN Toolbox.
  • Extract the ZIP file to your favourite directory.
  • Follow the Install RAVEN in MATLAB instructions below.

Advanced

  • This approach is recommended, but requires git to be installed.
  • In Terminal/Command Prompt, navigate to the desired installation directory and run the following Git command:
git clone --depth=1 https://github.com/SysBioChalmers/RAVEN.git

Upgrade RAVEN after Advanced installation

  • Close MATLAB.
  • Through your usual git routines, pull and checkout the latest commit on the main branch.
  • Follow the Install RAVEN in MATLAB instructions below.

Install RAVEN in MATLAB

checkInstallation
  • If RAVEN was cloned (the "advanced" approach) or downloaded (the "medium" approach), first open MATLAB and run the following command, where [location] is the directory where the RAVEN files can be found:
cd('[location]/RAVEN/installation'))
checkInstallation
  • checkInstallation installs and tests general functioning of RAVEN. It recognises which solvers are installed and sets the default solver (if possible gurobi, otherwise glpk).
  • The default RAVEN solver can be changed any time with: setRavenSolver('solverName'), where 'solverName' can be either 'gurobi', 'glpk', 'soplex' or 'cobra'.
  • checkInstallation also tests various programs that are distributed with RAVEN (BLAST+, DIAMOND, HMMER). Correct functioning of these programs generally are required for making models from homology (BLAST+, DIAMOND) or making models from KEGG (HMMER). If the tests of these programs fail, they need to be re-compiled from their corresponding source codes. See the documentation for the corresponding software for more details.
  • If you plan to train HMMs based on a KEGG FTP-dump (which is rarely done, as we already distribute these for you), you should run checkInstallation(true) to also test the CD-HIT and MAFFT binaries. If you run MATLAB on Windows, you should have Windows Subsystem for Linux installed.

Optional software

Solvers

RAVEN can function with various solvers. Gurobi is recommended, but other solvers might be suitable to fit different requirements:

Solver FBA1 MILPs2 Speed1 License Installation Comments
glpk Yes No 1x Open‑source RAVEN built-in. Default alternative.
scip Yes Yes 0.33x Open‑source Win: RAVEN built-in. Mac/Linux: SCIP. Not enabled by default. On Windows, run setRavenSolver('scip') to download and install the required pre-compiled files.
gurobi Yes Yes 4.2x Commercial Instructions. Free academic license available. Recommended alternative.
cobra Yes ? ? ? Instructions. Exact details depend which solver was enabled in COBRA Toolbox with changeCobraSolver.

1 When running solveLP.
2 When running fillGaps or tINIT.

Gurobi

  • Download and install Gurobi v7.5+ to your favourite location.
  • Make sure you retrieve and setup your Gurobi License. If suitable, academic license are offered for free.
  • Pay attention at what location the license file is stored, the default location is recommended.
  • To install Gurobi in MATLAB, follow the instructions.
  • Make sure that MATLAB remembers the Gurobi installation for next time, by running savepath.

COBRA Toolbox

  • To gain access to functions from the COBRA Toolbox and/or use whatever solver was setup in COBRA Toolbox, follow installation instructions provided here.
  • To use COBRA-specific functions on a model, you are advised to first change the model into COBRA-format, using modelCobra=ravenCobraWrapper(model).
  • To use COBRA-specified solvers (e.g. open-source GLPK solver), configure COBRA and RAVEN with the following commands:
changeCobraSolver('glpk')
setRavenSolver('cobra')

Uninstall

How to uninstall / remove RAVEN depends on how it was installed:

Easy

  • Uninstall RAVEN via the Add-Ons Explorer. This should automatically remove RAVEN from the MATLAB path.
  • To confirm that RAVEN has been removed, if you run removeRavenFromPath it should return: Unrecognized function or variable 'removeRavenFromPath'.

Medium or Advanced

  • Run which removeRavenFromPath and note down the path where RAVEN is installed.
  • Run removeRavenFromPath to remove all mentions to RAVEN from the MATLAB path.
    • You may want to repeat this step, to confirm that it has succeeded.
  • In your computer's file manager, remove the RAVEN folder and all its content.