Skip to content

anexVis/setup

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 

Repository files navigation

If you want to use anexVis, a web service is provided at https://anexvis.chpc.utah.edu

If you want to provide your own host, contribute to the code, or adopt it for your research, it is recommended to set it up on a server with Ubuntu 16.04 or higher.

This repo provides an installation script example that can be used to set up your own instance of anexVis web application. The application involves several components that need to be stitched together. In principle, the server components can be implemented separately. The example below only shows how to implement them in one single machine.

Preparation

OS

The application makes use of OpenCPU server runs on Ubuntu 16.04 or higher. Please make sure you have the appropriate OS before moving forward.

Data file

The data is stored in an HDF5 file which will be read to redis server (thus stay in memory for the whole time the application is running). Make sure you transfer this file to some place on the server. We recorded the path to this data file in DATAPATH

DATAPATH='/the/path/to/your/data/GTEx_V6-public.h5'

Give a path on your local machine to download and install the packages

program_dir=$HOME"/Programs"
mkdir -p $program_dir

Installation

[Optional] Ubuntu upgrade

sudo apt-get update
sudo apt-get dist-upgrade -y
sudo apt-get install -y software-properties-common
sudo add-apt-repository -y ppa:opencpu/opencpu-1.6
sudo apt-get update

Install an up-to-date R version

You may want to revise the mirror link depending on your location and your Ubuntu version.

sudo add-apt-repository -y "deb [arch=amd64] https://cran.cnr.berkeley.edu/bin/linux/ubuntu xenial/"
sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys E084DAB9
sudo apt-get update
sudo apt-get install -y r-base

OpenCPU

Install using package manager

sudo apt-get install opencpu

Start it

sudo service opencpu start

And make sure it works

curl http://localhost/ocpu/info

Redis server

Download, extract, compile and install

cd $program_dir
wget http://download.redis.io/releases/redis-3.2.8.tar.gz
tar -xzf  redis-3.2.8.tar.gz
cd redis-3.2.8/
make
sudo make install

R packages

Developer tools

sudo apt-get install git
sudo Rscript -e "install.packages(c('futile.logger','testthat', 'roxygen2'), repos='https://cran.cnr.berkeley.edu/',Ncpus=2)"
sudo Rscript -e "devtools::install_version('devtools', version='1.11.1', repos='https://cran.cnr.berkeley.edu/',Ncpus=2,quiet=TRUE)"

bioconductor dependencies

sudo Rscript -e 'source("https://bioconductor.org/biocLite.R");biocLite("rhdf5");'

rvislib - a dependency of ranexvis

cd $program_dir
git clone https://github.com/anexVis/rvislib.git
cd rvislib
sudo Rscript -e "devtools::install('.')"

rredis

At the time of this writing, rredis on CRAN has an unfixed bug which we don't want. The code below will install rredis from github.

sudo Rscript -e 'devtools::install_github("bwlewis/rredis"); devtools::install_dev_deps(".")'
redis-server &
disown

ranexvis

As ranexvis depends on all the components above, make sure OpenCPU and redis-server are started, and your data file is in place.

cd $program_dir
git clone https://github.com/anexVis/ranexvis.git

Replace the custom data path and install the package

Rscript -e `printf 'load("data/sysdata.rda");dbpath=list(gtex="%s");save(list=ls(),file="data/sysdata.rda")' $DATAPATH`
sudo Rscript -e "devtools::install('.', quick=TRUE, force_deps=FALSE, upgrade_dependencies=FALSE)"

Add ranexvis to the list of packages to pre-load by OpenCPU server. You can also do this manually by modifying the line preload in /etc/opencpu/server.conf

sudo sed -i '/preload/ c\    "preload": ["ranexvis", "ggplot2"]' /etc/opencpu/server.conf

Restart OpenCPU

sudo service opencpu restart

From the time OpenCPU server is up, it generally takes about 30 seconds to finish loading the whole data set. Until then, the gene list and other inputs won't be available.

Install anexvis-app

cd $program_dir
git clone https://github.com/anexVis/anexvis-app.git
sudo mv anexvis-app /var/www/html/

The app is accessible at http://url-to-your-apache-server/anexvis-app

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages