Important R Language MCQs ggplot2 with Answers 8

The quiz “R Language MCQS ggplot2” will help you check your ability to execute some basic operations on objects in the R language, and it will also help you understand some basic concepts. This quiz may also improve your computational understanding.

Quiz about R Language

1. Which is the R command for obtaining 1000 random numbers through normal distribution with mean 0 and variance 1?

 
 
 
 

2. A data analyst is working with the penguin’s data. They write the following code:
penguins %>%

The variable species includes three penguin species: Adelie, Chinstrap, and Gentoo. What code chunk does the analyst add to create a data frame that only includes the Gentoo species?

 
 
 
 

3. When programming in R, what is a pipe used as an alternative for?

 
 
 
 

4. Suppose you want to simulate a coin toss 20 times in R. Write the command.

 
 
 
 

5. Which of the following are standards of tidy data?

 
 
 
 

6. Which R function can be used to make changes to a data frame?

 
 
 
 

7. Data analysts are working with customer information from their company’s sales data. The first and last names are in separate columns, but they want to create one column with both names instead. Which of the following functions can they use?

 
 
 
 

8. Let us have 1000 random samples of size 6 under SRSWOR using the following population (111, 150, 121, 198, 112, 136, 114, 129, 117, 115, 186, 110, 121, 115, 114) which is the R command for repeating this procedure 1500 times?

 
 
 
 

9. In R the following are all atomic data types EXCEPT:

 
 
 
 

10. A data scientist is trying to print a data frame but when you print the data frame to the console output produces too many rows and columns to be readable. What could they use instead of a data frame to make printing more readable?

 
 
 
 

11. How sampling with and without replacement can be done using R?

 
 
 
 

12. You are cleaning a data frame with improperly formatted column names. To clean the data frame you want to use the clean_names() function. Which column names will be changed using the clean_names() with default parameters?

 
 
 
 

13. For the population y<-c(1,2,3,4,5), write the R command to find the median?

 

 
 
 
 

14. Why are tibbles a useful variation of data frames?

 
 
 
 

15. Which summary functions can you use to preview data frames in R Language?

 
 
 
 

16. What is the class of the object defined by the expression? x <- c(4,5,10)?

 

 
 
 
 

17. For the population y<-c(1,2,3,4,5), write the R command to find the mean?

 
 
 
 

18. In ggplot2, an _____ is a visual property of an object in your plot.

 
 
 
 

19. Write the R commands for generating 700 random variables from normal distribution by using the following information: Mean = 14, SD = 3, n = 5, k = 2000.

 
 
 
 

20. Data analysts are cleaning their data in R. They want to be sure that their column names are unique and consistent to avoid any errors in their analysis. What R function can they use to do this automatically?

 
 
 
 

Frequently Asked Questions About R Language MCQs ggplot2

R Language MCQs ggplot2 Function

  • What is the class of the object defined by the expression? x <- c(4,5,10)?  
  • In R the following are all atomic data types EXCEPT:
  • For the population y<-c(1,2,3,4,5), write the R command to find the mean.
  • For the population y<-c(1,2,3,4,5), write the R command to find the median.
  • Let us have 1000 random samples of size 6 under SRSWOR using the following population (111, 150, 121, 198, 112, 136, 114, 129, 117, 115, 186, 110, 121, 115, 114) which is the R command for repeating this procedure 1500 times?
  • Which is the R command for obtaining 1000 random numbers through normal distribution with mean 0 and variance 1?
  • How sampling with and without replacement can be done using R?
  • Write the R commands for generating 700 random variables from normal distribution by using the following information: Mean = 14, SD = 3, n = 5, k = 2000.
  • Suppose you want to simulate a coin toss 20 times in R. Write the command.
  • When programming in R, what is a pipe used as an alternative for?
  • Which of the following are standards of tidy data?
  • Which summary functions can you use to preview data frames in R Language?
  • Which R function can be used to make changes to a data frame?
  • Why are tibbles a useful variation of data frames?
  • Data analysts are cleaning their data in R.
  • They want to be sure that their column names are unique and consistent to avoid any errors in their analysis. What R function can they use to do this automatically?
  • Data analysts are working with customer information from their company’s sales data. The first and last names are in separate columns, but they want to create one column with both names instead. Which of the following functions can they use?
  • A data scientist is trying to print a data frame but when you print the data frame to the console output produces too many rows and columns to be readable. What could they use instead of a data frame to make printing more readable?
  • A data analyst is working with the penguin’s data. They write the following code: penguins %>% The variable species includes three penguin species: Adelie, Chinstrap, and Gentoo. What code chunk does the analyst add to create a data frame that only includes the Gentoo species?
  • You are cleaning a data frame with improperly formatted column names. To clean the data frame you want to use the clean_names() function. Which column names will be changed using the clean_names() with default parameters?
  • In ggplot2, an ———- is a visual property of an object in your plot.

R Language MCQs 2

Computer MCQs Online Test

Leave a Reply

Discover more from R Language Frequently Asked Questions

Subscribe now to keep reading and get access to the full archive.

Continue reading