You are on page 1of 2

Tutorial III

1. Given the following sequence of numbers 19, 16, 13, 11, 87, 54, 33
store them in a vector and write an R program to nd the maximum,
minimum and mean number.

2. Given the following sequence of numbers 18, 29,17 19, 19 ,19 20, 21.
Write an R program to establish which number is repeated the most and
the number of times it is repeated.

3. Given the following sequence of numbers 18, 29, 17, 11, 13 ,25 20, 21,
26, 28, 14, 20. Write an R program that lists the prime numbers in the
sequence.

4. Write an R script that requests a student to input their name, surname,


student number and degree program they are enrolled for and it prints
that to the screen.

5. Write a R program to create a sequence of random numbers from 10 to


100 and nd the mean of numbers from 20 to 50 and sum of numbers
from 10 to 80.

6. Write a R program to create a vector which contains 20 random integer


values between -100 and 100 and nds the maximum and the minimum
value of the list.

7. Given the following c(10,11,17,na,89,24,na) write an R program to


remove any missing values.

8. Download the Liver Disorders Data Set le from the UCI machine
learn-ing repository and perform the following tasks.

Find the class of the "liver" dataframe

Find the class of all the columns of the liver


dataFrame Get the summary of the liver dataFrame

Get the top 6 rows, view it in a spreadsheet format


Get row names

Get column names,

Get number of rows and get number of columns.


1

You might also like