1b. Manual Installation - Oshlack/Slinker GitHub Wiki
Via the command line/terminal, navigate to the folder where you would like Slinker installed and execute:
git clone [email protected]:Oshlack/Slinker.git
or git clone https://github.com/Oshlack/Slinker.git
Depending on whether you have setup SSH keys.
Slinker has both internal and external dependencies that need to be installed. But before we get to that, let's install Anaconda!
The Slinker installation process heavily relies on https://www.anaconda.com/. This simplifies the process of ensuring that the correct versions of dependent packages are installed. If these versions deviate, there is a risk that the output will differ from what was intended.
-
Download and Install Anaconda
-
Activate bioconda
Enter the below in order (!important)
conda config --add channels conda-forge
conda config --add channels defaults
conda config --add channels r
conda config --add channels bioconda
-
Create a new environment using the supplied yaml file
Navigate to where you installed the Slinker package and then execute
conda env create -f env/slinker.yml
.
This will create the "slinker" environment which you will need to activate each time you wish to use Slinker. -
Activate environment
Depending on your Anaconda version, either of these should do the trick.
source activate slinker
orconda activate slinker
.
Slinkers visualisation requires two in-house developed packages. The Slinker Visualisation package does the heavy lifting in terms of formatting files correctly for the Canvas package. The Canvas package is a general purpose visualisation tool, much in the spirit of the fantastic GViz R package... but for Python!
-
Install Slinker
From the clone root execute:
pip install tools/Slinker/.
-
Install Canvas
From the clone root execute:
pip install tools/Canvas/.
Slinker requires some big name tools to make the visualisations possible. Namely STAR, Samtools, and Bpipe.
- Install bpipe
-
Install stringtie2
Follow the steps outlined here. -
Install STAR
Follow the steps outlined here. -
Install Gffread
Follow the steps outlined here. -
Install Samtools
Follow the steps outlined here.
NOTE: There is some functionality that Slinker requires in more recent versions, please try and install 1.13 which is the version that Slinker has been tested on.
This is an easy one to start off with! Head over to bpipe's Github page. and download version 0.9.9.7 of bpipe (http://download.bpipe.org/versions/bpipe-0.9.9.7.tar.gz).
You can follow the instructions below, but all you really need to do is extract it somewhere and add the bin folder to your path.
Simon has created a lot of documentation on bpipe http://docs.bpipe.org.
Now obviously if you already have other methods of using these tools (modules/previous installations/whatever). Just make sure that the following paths are set and Slinker will run.
The first thing to do is to make life easy and set an environmental variable for the slinker directory:
export SLINKERDIR=/path/to/slinker_root
Now, you can either continue creating environment paths to each of the tool locations OR you can edit the tools.groovy file in $SLINKERDIR/workflows/tools.groovy.
-
Bpipe
In the bpipe installation directory, add the bin folder to the path:export PATH=<bpipe_installation_folder>/bin/:$PATH
-
Stringtie2
In the Stringtie2 installation directory:export stringtie=<stringtie_installation_folder>/stringtie
-
STAR
In the STAR installation directory:export star=<star_installation_folder>/source/STAR
-
Samtools
In the Samtools installation directory:export samtools=<samtools_installation_folder>/bin/samtools
-
Bpipe
In the bpipe installation directory, add the bin folder to the path:export PATH=<bpipe_installation_folder>/bin/:$PATH
- Simply enter the paths that you would typically assign to variables above in this file instead.
vi $SLINKERDIR/workflows/tools.groovy
If you already have these references or wish to use your own, use the gtf and fasta parameters to input them into the pipeline, i.e. use yours, not the below, save yourself this download if you want.
Rather than bundling some giant annotations in this repository, I thought it would be easier to just point you to the source.
- From the clone root execute:
wget https://ftp.ensembl.org/pub/release-96/fasta/homo_sapiens/dna/Homo_sapiens.GRCh38.dna.primary_assembly.fa.gz -P $PWD/references/
wget https://ftp.ensembl.org/pub/release-75/fasta/homo_sapiens/dna/Homo_sapiens.GRCh37.75.dna.primary_assembly.fa.gz -P $PWD/references/
- Now let's unpack those downloaded and supplied references:
gunzip $PWD/references/*.gz
Sorry to see you go! Uninstalling should be really easy with Anaconda after you have deactivated (conda deactivate slinker
).
conda remove --name slinker --all
Follow the relevant documentation on the https://www.anaconda.com/ website to uninstall conda, if required.