I have the new Ubuntu disco 19.04, and I followed the instructions here to install the new R 3.6.
However, after installing the key and adding the repository through:
sudo add-apt-repository 'deb https://cloud.r-project.org/bin/linux/ubuntu disco-cran35/'
And running:
sudo apt update
sudo apt install r-base
I get:
Reading package lists... Done
Building dependency tree
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:
The following packages have unmet dependencies:
r-base : Depends: r-base-core (>= 3.6.0-1cosmic) but 3.5.2-1build1 is to be installed
Depends: r-recommended (= 3.6.0-1cosmic) but 3.5.2-1build1 is to be installed
E: Unable to correct problems, you have held broken packages.
I could install R through
sudo apt install r-base
before adding the aforementioned repository, but version 3.5.2
is installed.
Does anyone have an idea how to install it without having to compile from source?
Ubuntu 20.04 is referred to as Focal Fossa, and the most recent version of R is 4.0.
I followed the same instructions, got R 3.5 as well.
Adding the repo's pubkey before running apt update
got me R 3.6.
These should be the steps to install R 3.6 into a fresh Ubuntu 19.04:
sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys E298A3A825C0D65DFD57CBB651716619E084DAB9
sudo add-apt-repository 'deb https://cloud.r-project.org/bin/linux/ubuntu disco-cran35/'
sudo apt update
sudo apt install r-base-dev
Changing the repository details allows installation onto other Ubuntu versions i.e. replace 'disco' with 'xenial' for Ubuntu 16.04.
Update Oct 2020: In the same vein (add repo, add repo keys, update, install), follow this tutorial at thinkr.fr by Sébastien Rochette to update Ubuntu to 20.* and R to 4.* As a bonus, it comes with installation tips for dependencies of spatial packages.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With