Data Science Questions and Answers - Literate Statistical Programming Part-2

1. Which of the following should be set on chunk by chunk basis to store results of computation?
a) cache=TRUE
b) cache=FALSE
c) caching=TRUE
d) none of the mentioned

Answer: a
Explanation: After the first run. The results are loaded from cache.

2. Dependencies are checked explicitly in caching caveats.
a) True
b) False

Answer: b
Explanation: Dependencies are not checked explicitly in caching caveats.

3. Original idea comes of Literate Statistical Practice from _______________
a) Don Knuth
b) Don Cutting
c) Douglas Cutting
d) All of the mentioned

Answer: a
Explanation: Literate programs are tangled to produce machine readable documents.

4. Point out the correct statement.
a) An article is stream of code and text
b) Analysis code is divided in to code chunks only
c) Literate programs are tangled to produce human readable documents
d) None of the mentioned

Answer: a
Explanation: Analysis code is divided in to code chunks and text.

5. Which of the following is required for literate programming?
a) documentation language
b) mapper language
c) reducer language
d) all of the mentioned

Answer: a
Explanation: Programming language is also required for literate programming.

6. Which of the following is required to implement a literate programming system?
a) A programming language like Perl
b) A programming language like Java
c) A programming language like R
d) All of the mentioned

Answer: c
Explanation: R is a language and environment for statistical computing and graphics.

7. Which of the following way is required to make work reproducible?
a) keep track of things
b) Save output
c) Save data in proprietary formats
d) None of the mentioned

Answer: a
Explanation: Save data in NON proprietary formats to make work reproducible.

8. Which of the following disadvantage does literate programming have?
a) Slow processing of documents
b) Code is not automatic
c) No logical order
d) All of the mentioned

Answer: a
Explanation: Code and text is in one place.

9. knitr supports only one documentation language.
a) True
b) False

Answer: b
Explanation: knitr supports various documentation languages.

10. Which of the following tool documentation language is supported by knitr?
a) RMarkdown
b) LaTeX
c) HTML
d) None of the mentioned

Answer: a
Explanation: knitr is available on CRAN.