The Console

Basic mathematical operations

Let’s get familiar with the Console by calculating some simple in RStudio. In it’s simplest form R can be used as very powerful calculator.

5+5

Now let’s try to do the same by using some mathematical operations such as subtraction ( - ), division ( / ), and multiplication ( * ).

Subtraction

5-3

Division

10/6

Multiplication

7*5

You can edit your code in the console by using the arrow keys on your keyboard. The UP and DOWN keys will re-run your code without typing it again. You may edit your code by using the LEFT and/or the RIGHT keys