Size: 2178
Comment: Add nav menu
|
Size: 4957
Comment: miniconda
|
Deletions are marked like this. | Additions are marked like this. |
Line 13: | Line 13: |
== Install miniconda/anaconda packages == Anaconda (or Conda) is a well known program for managing environments and packages. It is very popular inn bioinformatics as it allows users with little experience to easily install needed tools and all dependencies. It also makes it easy for users to load the specific environments they need without modifying their '''bashrc''' themselves. On this server you will find 2 versions of miniconda installed, miniconda3 for python 3 and miniconda2 for python 2.7 environments. Conda's users guide can be found here, https://docs.conda.io/projects/conda/en/latest/user-guide/index.html. ''' * Load conda module and set needed for conda to work. Be aware that this process rebase you default python bin folder into conda base folder. ''' {{{ module load miniconda3/4.8.2 source $CONDA_INIT }}} {{{ which python #/tools/software/bioinfo-tools/miniconda/miniconda3/bin/python }}} ''' * You can see all available environments * To make it easy for all users to locate needed environments, use descriptive names when making new environments, eg. software-exact_version_number. ''' {{{ conda info --envs # OR conda env list ## conda environments: ## #test /home/fhoma/.conda/envs/test #base * /tools/software/bioinfo-tools/miniconda/miniconda3 }}} ''' * Activate an existing environment ''' {{{ conda activate <environment_name> # For example, you can try conda activate base }}} ''' * Deactivate the current environment ''' {{{ conda deactivate }}} ''' * Load 2 conda environments (we do not recommend doing this as it may lead to big confusions) * Nested environment ''' {{{ conda activate --stack <env_name> }}} ''' * Create new conda environment, there are 2 ways of doing this * from scratch or from a YAML config file. The latter one will create the environment and install all listed software * You can also give a list of software and versions when installing from scratch * Replace <env_name>, with a descriptive name. ''' {{{ # Create an environment with only default packages conda create --name <env_name> # You can be asked to confirm the location of the location of the envs folder # Use the command below to accept any question by default conda create --yes --name <env_name> # Make an environment with python 3.6 conda create --yes --name <env_name> python=3.6 # Create an environment from YAML file conda env create -f <environment.yml> }}} ''' * Remove an unused environment ''' {{{ conda env remove --name <env_name> # OR conda remove --name <env_name> --all }}} * https://docs.conda.io/projects/conda/en/4.6.0/_downloads/52a95608c49671267e40c689e0bc00ca/conda-cheatsheet.pdf |
Installing software
Contents
Installing software or pipeline can be a difficult task to accomplish. Therefore we suggest all users to make the programs they installed available to all users whenever it is possible. In general programs/pipelines that should be available to all are installed in /tools folder. On this page will be described how to make tools available on our system for installation procedure of your specific program please refer to the instructions coming with that program.
Who can install software
In principle any users except students and guests should be able to install bioinfo tools in folders made for that purpose.
Install miniconda/anaconda packages
Anaconda (or Conda) is a well known program for managing environments and packages. It is very popular inn bioinformatics as it allows users with little experience to easily install needed tools and all dependencies. It also makes it easy for users to load the specific environments they need without modifying their bashrc themselves.
On this server you will find 2 versions of miniconda installed, miniconda3 for python 3 and miniconda2 for python 2.7 environments.
Conda's users guide can be found here, https://docs.conda.io/projects/conda/en/latest/user-guide/index.html.
module load miniconda3/4.8.2 source $CONDA_INIT
which python #/tools/software/bioinfo-tools/miniconda/miniconda3/bin/python
conda info --envs # OR conda env list ## conda environments: ## #test /home/fhoma/.conda/envs/test #base * /tools/software/bioinfo-tools/miniconda/miniconda3
conda activate <environment_name> # For example, you can try conda activate base
conda deactivate
conda activate --stack <env_name>
Replace <env_name>, with a descriptive name.
# Create an environment with only default packages conda create --name <env_name> # You can be asked to confirm the location of the location of the envs folder # Use the command below to accept any question by default conda create --yes --name <env_name> # Make an environment with python 3.6 conda create --yes --name <env_name> python=3.6 # Create an environment from YAML file conda env create -f <environment.yml>
conda env remove --name <env_name> # OR conda remove --name <env_name> --all
Install R packages
- Packages for R are installed within R, so to install R packages, you will first need to load the module R and run R.
module load R R
Use the following R command to print where are the R libraries. Users libraries are installed in /tools/R_libs/3.6.1
.libPaths() #[1] "/tools/R_libs/3.6.1" #[2] "/opt/ohpc/pub/libs/gnu8/R/3.6.1/lib64/R/library"
- To see all available/installed packages
.packages(all.available=T)
To install R packages and dependancies. Installation will automatically be done in a /tools/R_libs/3.6.1 if permissions allows it. If not you could be asked to create a private one.
install.packages(c("<package1>", "<package2>,..."), dep=T)
To install BIOINFORMATICS R PACKAGES, we recommend to use "bioconductor" channels.
library(BiocManager) BiocManager::install(c("<package1>", "<package2>",...))
Read more about R and bioconductor:
^#top |
FINISH>> |