Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Which version of R is running in my computer?

There are two R directories on my computer:
one is /home/R-2.15.2,the other is /home/R-2.15.1,
when I input R , I can start R, now I want to know which R is running: 2.15.1 or 2.15.2?

like image 776
showkey Avatar asked Apr 13 '13 01:04

showkey


People also ask

How do I check my R version?

In the R terminal, type R. version . It's R. version .

What is the current version of R?

R version 4.2.1 (Funny-Looking Kid) has been released on 2022-06-23. R version 4.2.0 (Vigorous Calisthenics) has been released on 2022-04-22. R version 4.1.3 (One Push-Up) was released on 2022-03-10.

How do I change R version?

You can select different versions of R by selecting it from the drop down list at the top of the browser window. The drop down menu will allow you to select the version of R you want to use. When you switch versions, the system will ask if you want to save your workspace before restarting your session.

Which R version should I use?

For most users we would recommend using the 'native' build, that is the 32-bit version on 32-bit Windows and the 64-bit version of 64-bit Windows.


2 Answers

05/20/2021 Update:

It should be R.version now


In addition to @Piotr Jaszkowski, R.Version() should do the work as well

like image 76
yujingz Avatar answered Sep 28 '22 02:09

yujingz


Run R --version there's info about version on the first line.

Edit: If you ask this question then I bet that R is not running from any of these directories. Check $PATH env variable to get information where binaries are looked for and in which order.

Edit 2: Use type shell command to find where binary for given command is stored, -a for all paths, -f for the hashed one (basically: most recently used).

like image 26
Piotr Jaszkowski Avatar answered Sep 28 '22 02:09

Piotr Jaszkowski