Skip to content
Prev 392314 / 398502 Next

Problem installing R 4.2 on Ubuntu 20-04

I am failing to get R 4 installed on Ubuntu. I am following the
instructions given here:
https://cran.r-project.org/bin/linux/ubuntu/

These are the errors I am getting:
<start>
parallels at ubuntu-linux-20-04-desktop:~/Downloads/fragpipe/bin$ sudo
apt install --no-install-recommends r-base
[sudo] password for parallels:
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 (>= 4.2.1-1.2004.0) but it is not going
to be installed
          Depends: r-recommended (= 4.2.1-1.2004.0) but it is not
going to be installed
E: Unable to correct problems, you have held broken packages.
<end>


This is the tail of the source.lists file:

<start>
deb https://cloud.r-project.org/bin/linux/ubuntu focal-cran40/
# deb-src https://cloud.r-project.org/bin/linux/ubuntu focal-cran40/
<end>

This is the head of executing: apt-cache policy r-base
<start>
arallels at ubuntu-linux-20-04-desktop:~/Downloads/fragpipe/bin$
apt-cache policy r-base
r-base:
  Installed: (none)
  Candidate: 4.2.1-1.2004.0
  Version table:
     4.2.1-1.2004.0 500
        500 https://cloud.r-project.org/bin/linux/ubuntu focal-cran40/ Packages
     4.2.0-1.2004.0 500
        500 https://cloud.r-project.org/bin/linux/ubuntu focal-cran40/ Packages
     4.1.3-1.2004.0 500
        500 https://cloud.r-project.org/bin/linux/ubuntu focal-cran40/ Packages
     4.1.2-1.2004.0 500

<end>

End this is for executing apt-cache policy r-base-core

<start>
parallels at ubuntu-linux-20-04-desktop:~/Downloads/fragpipe/bin$
apt-cache policy r-base-core
r-base-core:
  Installed: (none)
  Candidate: 3.6.3-2
  Version table:
     3.6.3-2 500
        500 http://ports.ubuntu.com/ubuntu-ports focal/universe arm64 Packages
        100 /var/lib/dpkg/status

<end>

Someone else described the same/similar problem here:

https://askubuntu.com/questions/1373827/problems-installing-latest-version-of-r-in-ubuntu-20-04-lts

What step did I miss executing?

Best regards
Witek


--
Witold Eryk Wolski