Wednesday, July 19, 2017

Installation of R in Ubuntu

Dear Technocrates,

Now a days R is getting more and more focus due to its ease of use for implementation of machine learning algorithms on large data analysis projects and for data visualization.

In this post I am giving steps to install R and Rstudio in your Ubuntu Machine. Installation of R/Rstudtio in ubuntu is just 3 steps procedure.

1. sudo apt-get update
2. sudo apt-get install r-base

These commands will install available version of R in your machine. You can check the version of R by type the command R on your terminal. To come out of terminal just type

quit();

It will ask to save or not to save your workspace as per your choice just come out of the terminal.
To install the R studio now download the rstudio-1.0.143-amd64.deb in your system and just give the command sudo gdebi rstudio-1.0.143-amd64.deb . Ensure that you are in the same directory in which debian file is downloaded or you have given the right path to that file.
Note: if gdebi is not installed in you system just install it first by simple command:
sudo apt-get install gdebi

You are done. just type rstudio in your terminal as shown:



you will have the rstudio GUI interface in your system as shown below.


Now you can play with features of R on this Rstudio interface. For more updates of programming with R keep visiting the blog.

Rstudio is a package based programming framework. You just install the packages form right side window packages and install option. just type the package you need to install and it will be installed with no efforts.

Most of the packages will be installed simply. But a few new packages may throw error. It is due to version of R. If you have some older version of R installed on your machine there is no escape plan to install new packages in Rstudio other than upgrading your R version.

How to upgrade R in Ubuntu
Upgrading R version in Ubuntu is tricky procedure. Visit this post to find the steps to upgrade R version in Ubuntu machine.


1 comment: