Hi Xianrong and Gildas, this method works, but is a little bit outdated. Please use the setup_r_environment like used here: https://github.com/galaxyproject/tools-iuc/blob/master/packages/package_dese... You can use this script with small modifications to create you such a file from scratch: https://github.com/bioarchive/aRchive_source_code/blob/master/get_galaxy_too... At least to get started. An other possibility is to use conda dependencies. So if you R package is already in conda/bioconda you don't need a tool_depenencies.xml file at all. Just specify the requirement tag in your tool with the conda package name and version and activate conda in Galaxy. This will do the trick. -> Only available in 16.01. Ciao, Bjoern
Hi,
For me, three solutions : - You can find existing packages which will install your library (https://testtoolshed.g2.bx.psu.edu/view/jeltje/package_dnacopy_1_40_0/118417...). So you will just need to link a requirement (https://wiki.galaxyproject.org/Admin/Tools/ToolConfigSyntax#A.3Crequirements...) and a tool_dependencies.xml file - If not, you can write your own package. But thanks to Ross Lazarus, to deal with dependencies of dependencies of dependencies, there is a tool for that https://testtoolshed.g2.bx.psu.edu/view/fubar/biocdepgen_r_3_1_2/faafc60f3d6... - If you lack of time, you install R and needed libraries on your serveur.
Unfortunately, I can’t explain you why you couldn’t install your library through your script because R use to allow installing in the user home.
Gildas
----------------------------------------------------------------- Gildas Le Corguillé - Bioinformatician/Bioanalyste Plateforme ABiMS (Analyses and Bioinformatics for Marine Science)
Station Biologique de Roscoff - UPMC/CNRS - FR2424 Place Georges Teissier 29680 Roscoff FRANCE tel: +33 2 98 29 23 81 http://abims.sb-roscoff.fr ------------------------------------------------------------------
Le 26 févr. 2016 à 09:03, Xianrong Wong <wongxr@gmail.com <mailto:wongxr@gmail.com>> a écrit :
Hi, I am trying to package an R script (that requires certain R packages) into a galaxy tool. Any advice would be deeply appreciated!
I have tested it on planemo and it works. When I tried the version I uploaded onto the toolshed, I got an error saying that the R packages do not exist. I next added the following lines to the R script:
source("https://bioconductor.org/biocLite.R")
biocLite()
biocLite(c("DNAcopy","preprocessCore"))
and I got the following error when running the installed tool on galaxy:
Installing package(s) ‘DNAcopy’, ‘preprocessCore’ Warning in install.packages(pkgs = doing, lib = lib, ...) : 'lib = "/usr/local/lib/R/site-library"' is not writable Error in install.packages(pkgs = doing, lib = lib, ...) : unable to install packages Calls: biocLite ... .biocLiteInstall -> .reposInstall -> install.packages Execution halted ___________________________________________________________ Please keep all replies on the list by using "reply all" in your mail client. To manage your subscriptions to this and other Galaxy lists, please use the interface at: https://lists.galaxyproject.org/
To search Galaxy mailing lists use the unified search at: http://galaxyproject.org/search/mailinglists/
___________________________________________________________ Please keep all replies on the list by using "reply all" in your mail client. To manage your subscriptions to this and other Galaxy lists, please use the interface at: https://lists.galaxyproject.org/
To search Galaxy mailing lists use the unified search at: http://galaxyproject.org/search/mailinglists/