-
Notifications
You must be signed in to change notification settings - Fork 24
installation
The easiest way is certainly using conda, where smudgeplot package is available. If you have conda
installed, getting smudgeplot is simply
conda install -c bioconda smudgeplot
which installs the package to the currently active conda environment. Note that the conda package does not contain the smudge_pairs
program for more efficient extraction of k-mer pairs. To install smudge_pairs
, see tbenavi1/KMC.
To install and Smudgeplot, you will need python3
and R
with a couple of standard packages. Here are step by instructions to install smudgeplot assuming you have both python3
and R
installed already as well as R package devtools
(the rest of the dependencies are installed automatically).
Download this repository
git clone https://github.com/KamilSJaron/smudgeplot
cd smudgeplot
The next step will dependent wither it will be a local or global installation.
You need to install the smudgeplot
R package for plotting and make sure that some python dependencies (numpy
and scipy
) are present.
Rscript install.R
pip3 install -r requirements.txt
Then you just need to install following two scripts:
install -C exec/smudgeplot.py /usr/local/bin
install -C exec/smudgeplot_plot.R /usr/local/bin
smudgeplot.py
is a python script that is the user interface and smudgeplot_plot.R
is an R script for plotting internally called by smudgeplot.py
, but accessible to user if desired. To check if the installation is working run
smudgeplot.py --version
if you see the version of smudgeplot
printed, everything should be alright.
If the R is correctly configured, you should be able to install the R library directly exactly the same as for the global installation.
Rscript install.R
The python requirements should be installed already, these are very standard libraries that should be available on every cluster. If not, the dependencies can be installed in a virtual environment.
Finally, you probably won't be allowed to install the script to /usr/local/bin
, then you can install them somewhere where your console will see it (i.e. on one of the places specified in environmental variable $PATH
). If you are not sure what I just asked you to do, check the explanation of veriable PATH on wikipedia and this page that says how to change it or perhaps ask someone around. Here is an example with bin
directory located at your home (~
)
mkdir -p ~/bin
install -C exec/smudgeplot.py ~/bin
install -C exec/smudgeplot_plot.R ~/bin
~/bin
must be mentioned in PATH
, so if it's not, you can add it by
export PATH="$PATH:~/bin" >> ~/.bashrc
source ~/.bashrc
Again, you can verify that it works
smudgeplot.py --version
In some instances (reported in an virtual machine Ubuntu install in inssue #94), there is a strange error popping when plotting.
Warning messages:
1: In png(paste0(args$output, "_smudgeplot_log10.png")) :
unable to load shared object '/home/ubuntu/miniconda3/envs/smudgeplot/lib/R/library/grDevices/libs//cairo.so':
libXrender.so.1: cannot open shared object file: No such file or directory
2: In png(paste0(args$output, "_smudgeplot_log10.png")) :
failed to load cairo DLL
this seems to be resolved by conda install -c conda-forge xorg-libxrender
.