Gero
Gero

Reputation: 157

Error: Bioconductor version '3.13' requires R version '4.1' (R version 4.0.2)

I found 'similar' questions from other users but none of the answers worked. I am trying to install these packages among others:

if (!require("BiocManager"))
  install.packages("BiocManager")
BiocManager::install("maEndToEnd", version = "devel") 

if (!require("BiocManager"))
  install.packages("BiocManager")
BiocManager::install("ArrayExpress")
----------------------------------------------------------
Error: Bioconductor version '3.13' requires R version '4.1' 

My R version 4.0.2, my OS is Ubuntu 20.10 I thought that maybe I could:

a) Change my R version (I did not find for ubuntu R version 4.1)

b) Change my Bioconductor version. For that reason I executed:

if (!requireNamespace("BiocManager", quietly = TRUE))
    install.packages("BiocManager")
BiocManager::install(version = "3.12")
------------------------------------------------------
Error in packageVersion("BiocManager") : 
  there is no package called ‘BiocManager’
install("BiocManager")
------------------------------
Error: Can't find 'BiocManager'
´´´

I also tried so many things that I believe I just made worse the situation by eliminating packages from other libraries:  
/usr/lib/R/site-library 
/home/usr_name/R/x86_64-pc-linux-gnu-library/4.0

This are the packages directories I currently have:

library()
------------------------------------
 Packages in library ‘/usr/lib/R/site-library’:

askpass                    
assertthat                
backports              
base64enc                 
BH                    
Metapackage
bit                       
bit64                     
bitops                    
blob                       
brew                      
callr                     
cli                       
cliapp                  
clipr                      
colorspace                
and
                 
etc...

Packages in library ‘/usr/lib/R/library’:  

base 
boot
for

class
cluster
Extended

etc ...

How may I proceed? As you can tell I am a beginner in everything related to informatics. Any detail would be appreciated.

Upvotes: 0

Views: 5228

Answers (2)

Martin Morgan
Martin Morgan

Reputation: 46866

'R-4.1' is what current R-devel will become; R-devel is usually installed from source on linux platforms, but is conveniently available as rocker https://hub.docker.com/r/rocker/r-devel/ and Bioconductor https://hub.docker.com/r/bioconductor/bioconductor_docker/tags (look for the 'devel' tag) docker images.

The report about

if (!requireNamespace("BiocManager", quietly = TRUE))
    install.packages("BiocManager")
BiocManager::install(version = "3.12")
------------------------------------------------------
Error in packageVersion("BiocManager") : 
  there is no package called ‘BiocManager’

looks incomplete. What happens with

if (!requireNamespace("BiocManager", quietly = TRUE))
    install.packages("BiocManager")

? It should install (successfully) BiocManager, and packageVersion("BiocManager") should report a version. Perhaps it would help to start a new session?

For what it's worth, here's the 'version string' that reports 'R under development' but also version 4.1.0

> R.version
               _
platform       x86_64-apple-darwin17.7.0
arch           x86_64
os             darwin17.7.0
system         x86_64, darwin17.7.0
status         Under development (unstable)
major          4
minor          1.0
year           2021
month          02
day            10
svn rev        79979
language       R
version.string R Under development (unstable) (2021-02-10 r79979)
nickname       Unsuffered Consequences

Upvotes: 2

MånsT
MånsT

Reputation: 974

Unless you really need a particular version of a BioConductor package, you don't need to specify version. Try the following standard approach and see if that works:

install.packages("BiocManager")
library(BiocManager)
install() # Install BioConductor core packages
install("maEndToEnd")
install("ArrayExpress")

Upvotes: 4

Related Questions