R Programming Questions and Answers – Visualizing Data – 1

This set of R Programming Language Multiple Choice Questions & Answers (MCQs) focuses on “Visualizing Data – 1”.

1. Which of the following method make vector of repeated values?
a) rep()
b) data()
c) view()
d) read()
View Answer

Answer: b
Explanation: data() load (often into a data.frame) built-in dataset.

2. Which of the following finds the position of a quantile in a dataset?
a) quantile()
b) barplot()
c) barchart()
d) rep()
View Answer

Answer: a
Explanation: barplot() produces a bar graph.

3. Which of the following function cross-tabulate tables using formulas?
a) table
b) stem
c) xtabs
d) read
View Answer

Answer: d
Explanation: table() list all values of a variable with frequencies.

advertisement
advertisement

4. Which of the following groups find the correlation matrix?
a) factor.model
b) col.max(x)
c) stem
d) which.max(x)
View Answer

Answer: a
Explanation: factor.congruence is used to find the factor congruence coefficients.

5. which of the following statement make a mosaic plot?
a) histogram()
b) mosaicplot()
c) bar()
d) which.max(x)
View Answer

Answer: b
Explanation: histogram() is lattice command for producing a histogram.

Note: Join free Sanfoundry classes at Telegram or Youtube

6. Which of the following compute proportions from a contingency table?
a) par()
b) prop.table()
c) anova()
d) mosaicplot()
View Answer

Answer: b
Explanation: par() is used to query and edit graphical settings.

7. Which of the following is lattice command for producing a scatterplot?
a) plot()
b) lm()
c) xyplot()
d) anova()
View Answer

Answer: c
Explanation: plot() produces a scatterplot.

advertisement

8. Which of the following builds empirical cumulative distribution function?
a) ecdf()
b) cum
c) cumsum
d) lm()
View Answer

Answer: a
Explanation: cumsum() is used to produce running total of values for input vector.

9. Which of the following is used to view dataset in a spreadsheet-type format ?
a) Disp()
b) View()
c) Seq()
d) lm()
View Answer

Answer: b
Explanation: seq() make arithmetic progression vector.

advertisement

10. ________ function carries out a chi-square test.
a) chisq.test()
b) t.test()
c) prop.test()
d) fisher.test()
View Answer

Answer: a
Explanation: prop.test() is used to inference for 1 proportion using normal approx.

Sanfoundry Global Education & Learning Series – R Programming Language.

Here’s the list of Best Books in R Programming Language.

To practice all areas of R Programming Language, Here is complete set of 1000+ Multiple Choice Questions and Answers.

advertisement
advertisement
Subscribe to our Newsletters (Subject-wise). Participate in the Sanfoundry Certification contest to get free Certificate of Merit. Join our social networks below and stay updated with latest contests, videos, internships and jobs!

Youtube | Telegram | LinkedIn | Instagram | Facebook | Twitter | Pinterest
Manish Bhojasia - Founder & CTO at Sanfoundry
Manish Bhojasia, a technology veteran with 20+ years @ Cisco & Wipro, is Founder and CTO at Sanfoundry. He lives in Bangalore, and focuses on development of Linux Kernel, SAN Technologies, Advanced C, Data Structures & Alogrithms. Stay connected with him at LinkedIn.

Subscribe to his free Masterclasses at Youtube & discussions at Telegram SanfoundryClasses.