This is a test version of Biostars. For the public version, visit https://www.biostars.org.
Necessary Software Package Built For Earlier Version Of R, Now What?

I am trying to download the package shRNAseq (http://rock.icr.ac.uk/software/shrnaseq.jsp) for analysis of this data: Interpreting counts in a tabular file

However, I get the following error message (I have R version 3.0.1):

> library(shRNAseq)
Error: package ‘shRNAseq’ was built before R 3.0.0: please re-install it

Perhaps it would be more appropriate to contact the developer about this, but I suspect that the issue at hand is more general than just for this particular case: what is the best follow-up step if a package is designed for an earlier version of R, and you need the newer version for all your other stuff? Would you in fact install an older version of R for the purpose of running this package, and then switch back and forth between the versions? Seems quite cumbersome, but I'm not quite seeing any alternative way of solving this issue.

r

2 answers

$ R
> install.packages('devtools')
> library(devtools)
> install_url('http://rock.icr.ac.uk/software/shrnaseq/shRNAseq_0.3.tar.gz')

You just need to re-install the source package so that any binary components are built under the new version of R. The above is one way to accomplish this.

Thanks for the tip, but now it seems I'm getting another error message. The same is true when I try with Michael's method, I get the same error message about NAMESPACE then as well. Any ideas?

> library(devtools)
> install_url('http://rock.icr.ac.uk/software/shrnaseq/shRNAseq_0.3.tar.gz')
Downloading shRNAseq_0.3.tar.gz from http://rock.icr.ac.uk/software/shrnaseq/shRNAseq_0.3.tar.gz
Installing package from /tmp/RtmpeF1G84/shRNAseq_0.3.tar.gz
Installing shRNAseq
'/usr/lib/R/bin/R' --vanilla CMD INSTALL '/tmp/RtmpeF1G84/shRNAseq'  \
  --library='/usr/local/lib/R/site-library' --with-keep.source  \
  --install-tests

* installing *source* package 'shRNAseq' ...
ERROR: a 'NAMESPACE' file is required
* removing '/usr/local/lib/R/site-library/shRNAseq'
Error: Command failed (1)
>

I think now it's the time to get the original author of the software involved, even though we could do it ourselves, this is not a sustainable.

Yes. I think this is supposed to be one of the benefits of managed repositories such as Bioconductor.

Btw, does devtools also contain make and the compilers to build c/fortran code in windows?

No. Devtools is simply a collection of R functions that ease development in R. As such, it is primarily designed for R developers, so build tools are assumed to be present.

I guess you are on Windows.

You should re-install the package and do as R requests. You can install the source packages (labelled "Mac/Linux"), they do only contain R code and therefore can be installed from source on any OS without further tools. Download the package tar.gz file and run R CMD INSTALL package.tar.gz. See: http://cran.r-project.org/doc/manuals/r-release/R-admin.html#Installing-packages

Log in to answer this question.