23 Questions
What is the primary use of R programming language?
Data Science
What is the significance of the matrix() function in R?
It creates a two-dimensional array
How can you access the element in the 2nd row and 3rd column of a matrix P?
P[2,3]
What is the department of the employee with emp_id 4?
HR
What is the purpose of the byrow argument in the matrix() function?
To arrange elements sequentially by row
What is the type of the start_date column in the employee_data dataframe?
Date
What is the difference between a matrix and an array in R?
A matrix is a two-dimensional array, while an array can be more than two-dimensional
What is the purpose of the Pearson correlation test?
To evaluate the association between two variables
What is the output of the command print(P[2,])?
All elements in the 2nd row
How many rows are in the employee_data dataframe after expansion?
8
What is the name of the employee with emp_id 3?
Michelle
What is the dimension of the array created in the example?
4x2x3
What is the output of print(result[3,2,2])
?
12
How are the columns and rows named in the matrix?
Using the column.names and row.names functions
What is the data type of the object 'factor.data'?
Factor
What is the purpose of a factor in R?
To store categorical data
What is the structure of a data frame in R?
A table with variables and observations
What type of relationship does the Pearson correlation coefficient measure?
Linear dependence
What is the assumption of the Spearman rho test?
Variables should be measured on an ordinal or continuous level
What is the purpose of the Shapiro test?
To check for normality of distribution
When would you use Kendall tau test?
When there are tied ranks
What is the graphical method to check for normality of distribution?
Q-Q plot
What is the condition to use Pearson correlation coefficient?
Variables should be measured on an ordinal or continuous level and should be normally distributed
Test your understanding of R programming basics, including data types such as numerical, integer, logical, and character, as well as matrices in R. This quiz covers the fundamentals of R programming, a popular language used in data science and statistics.
Make Your Own Quizzes and Flashcards
Convert your notes into interactive study material.
Get started for free