Starting from:

$24.99

UCS410 Experiment 1- Basics of R programming Solution

Experiment 1: Basics of R programming

We hope you already have R and RStudio installed in your computers. Good luck with your programming in R! Let us start with the very basics of R programming here in our first Lab :)
If this is the first time, you are using R, then there is a lot to explore. You can try making codes for the following problems. This will give you a general idea of how to use R and over the next few labs you will learn more.

(1) Create a vector c = [5,10,15,20,25,30] and write a program which returns the maximum and minimum of this vector.
(2) Write a program in R to find factorial of a number by taking input from user. Please print error message if the input number is negative.
(4) Write an R program to make a simple calculator which can add, subtract, multiply and divide.
(5) Explore plot, pie, barplot etc. (the plotting options) which are built-in functions in R.

2

More products