The Quiz is about R Programming Quiz with Answers. There are 20 multiple-choice questions covering different topics related to R Language Programming. Let us start with the R Programming Quiz now.
Online R Programming Quiz with Answers
Online R Programming Quiz with Answers
- What is the main reason for using the R language?
- In R, what is the result of the function as.numeric(TRUE)?
- In R, variables are typically assigned using <-, but they can also be assigned using which of the following symbols?
- Which command in R would return the following character vector? “Imdad” “Usman” “Ali” “Amir”
- In R, assume you have a vector named “age,” and each element in the vector is the age of one person in a group. The vector has the following content: 24 32 46 19. What will be the result if you issue the age[-2] command?
- Assume the array books_array contains 6 elements. The array has three rows and two columns and appears as follows:
[,1] [,2]
[1,] “It” “Dr. Sleep”
[2,] “Misery” “Carrie”
[3,] “The Shining” “The Mist”
Which of the following commands will return “The Shining”?
- In R language, which command returns the last six elements of a data object such as a data frame?
- Assume that the function add is defined as follows:
add <- function(x,y) {
(x + y)
return (x – y)
temp <<- (x * y)
return (x / y)
}
What will be the output if you issue the command add(10,5)? - What is the first step you must take before you can read an Excel spreadsheet in R?
- After installing and calling the httr library in R, which method should you use to update a resource?
- In R, what is the result of the function as.integer(3.3)?
- In R, which command removes a variable from memory?
- In R, assume a character vector called “names” has the following contents: “Harry” “Jimmy” “Tammy” Which command would return the following logical vector? FALSE TRUE FALSE
- In R, assume you have a vector named “age,” and each element in the vector is the age of one person in a group. Which command must you use to reorder the ages from youngest to oldest?
- In R, which command will output the data from the Nile built-in data set?
- In R, which command should you use to insert a new row into a data frame?
- To perform a one-way Analysis of variance, one can use a function
- How many elements will be in vector $b$, if b <- 10:15
- All columns in a matrix must have the
- For a matrix $X$ of order $n\times p$ and a vector $Y$ of order $n\times 1$, one can find regression coefficients using