Wednesday, 25 January 2017

Installng RStudio on Ubuntu

Go to https://www.rstudio.com/products/rstudio/download/ and download the current version of the Installer for Debian. I downloaded file described as "RStudio 1.0.136 - Ubuntu 12.04+/Debian 8+ (64-bit)" which is a .deb file: rstudio-1.0.136-amd64.deb.

Initally, installation failed:


$ sudo dpkg -i rstudio-1.0.136-amd64.deb

(Reading database ... 226670 files and directories currently installed.)
Preparing to unpack rstudio-1.0.136-amd64.deb ...
Unpacking rstudio (1.0.136) over (1.0.136) ...
dpkg: dependency problems prevent configuration of rstudio:
rstudio depends on libjpeg62; however:
Package libjpeg62 is not installed.
rstudio depends on libgstreamer0.10-0; however:
Package libgstreamer0.10-0 is not installed.
rstudio depends on libgstreamer-plugins-base0.10-0; however:
Package libgstreamer-plugins-base0.10-0 is not installed.

dpkg: error processing package rstudio (--install):
dependency problems - leaving unconfigured
Processing triggers for shared-mime-info (1.5-2ubuntu0.1) ...
Processing triggers for hicolor-icon-theme (0.15-0ubuntu1) ...
Processing triggers for bamfdaemon (0.5.3~bzr0+16.04.20160824-0ubuntu1) ...
Rebuilding /usr/share/applications/bamf-2.index...
Processing triggers for gnome-menus (3.13.3-6ubuntu3.1) ...
Processing triggers for desktop-file-utils (0.22-1ubuntu5) ...
Processing triggers for mime-support (3.59ubuntu1) ...
Errors were encountered while processing:
rstudio



I then ran a command which is supposed to fix broken packages:


$ sudo apt-get -f install

Reading package lists... Done
Building dependency tree
Reading state information... Done
Correcting dependencies... Done
The following additional packages will be installed:
libgstreamer-plugins-base0.10-0 libgstreamer0.10-0 libjpeg62
Suggested packages:
libvisual-0.4-plugins gstreamer0.10-tools gstreamer0.10-plugins-base
The following NEW packages will be installed
libgstreamer-plugins-base0.10-0 libgstreamer0.10-0 libjpeg62
0 to upgrade, 3 to newly install, 0 to remove and 40 not to upgrade.
1 not fully installed or removed.
Need to get 1,168 kB of archives.
After this operation, 4,420 kB of additional disk space will be used.
Do you want to continue? [Y/n] y
Get:1 http://gb.archive.ubuntu.com/ubuntu xenial/universe amd64 libjpeg62 amd64 1:6b2-2 [78.9 kB]
Get:2 http://gb.archive.ubuntu.com/ubuntu xenial/universe amd64 libgstreamer0.10-0 amd64 0.10.36-1.5ubuntu1 [646 kB]
Get:3 http://gb.archive.ubuntu.com/ubuntu xenial/universe amd64 libgstreamer-plugins-base0.10-0 amd64 0.10.36-2 [443 kB]
Fetched 1,168 kB in 4s (247 kB/s)
Selecting previously unselected package libjpeg62:amd64.
(Reading database ... 226670 files and directories currently installed.)
Preparing to unpack .../libjpeg62_1%3a6b2-2_amd64.deb ...
Unpacking libjpeg62:amd64 (1:6b2-2) ...
Selecting previously unselected package libgstreamer0.10-0:amd64.
Preparing to unpack .../libgstreamer0.10-0_0.10.36-1.5ubuntu1_amd64.deb ...
Unpacking libgstreamer0.10-0:amd64 (0.10.36-1.5ubuntu1) ...
Selecting previously unselected package libgstreamer-plugins-base0.10-0:amd64.
Preparing to unpack .../libgstreamer-plugins-base0.10-0_0.10.36-2_amd64.deb ...
Unpacking libgstreamer-plugins-base0.10-0:amd64 (0.10.36-2) ...
Setting up libjpeg62:amd64 (1:6b2-2) ...
Setting up libgstreamer0.10-0:amd64 (0.10.36-1.5ubuntu1) ...
Setting up libgstreamer-plugins-base0.10-0:amd64 (0.10.36-2) ...
Setting up rstudio (1.0.136) ...
Processing triggers for libc-bin (2.23-0ubuntu5) ...



Installation now works:


$ sudo dpkg -i rstudio-1.0.136-amd64.deb

(Reading database ... 226736 files and directories currently installed.)
Preparing to unpack rstudio-1.0.136-amd64.deb ...
Unpacking rstudio (1.0.136) over (1.0.136) ...
Setting up rstudio (1.0.136) ...
Processing triggers for shared-mime-info (1.5-2ubuntu0.1) ...
Processing triggers for hicolor-icon-theme (0.15-0ubuntu1) ...
Processing triggers for bamfdaemon (0.5.3~bzr0+16.04.20160824-0ubuntu1) ...
Rebuilding /usr/share/applications/bamf-2.index...
Processing triggers for gnome-menus (3.13.3-6ubuntu3.1) ...
Processing triggers for desktop-file-utils (0.22-1ubuntu5) ...
Processing triggers for mime-support (3.59ubuntu1) ...



I am running 64-bit Ubuntu 16.04.

Prior to installing RStudio I didn't install R language. Therefore, when I tried to launch RStudio, I got the following dialog:


After I installed the R language by executing:


$ sudo apt-get install r-base



...RStudio launched as expected:

Post a Comment