R Programming Language Certification Communication & Stakeholder Relations 4 — Questions and Answers
Question 1: A stakeholder wants the same report delivered as both a slide deck and a Word document. Which R Markdown output format supports multiple formats from one source file?
- Multiple output: entries in the YAML header or separate render() calls with different formats (Correct answer)
- Writing two separate .Rmd files
- Using PowerPoint directly
- Exporting from Excel
Correct answer: Multiple output: entries in the YAML header or separate render() calls with different formats
R Markdown's YAML header supports multiple output formats (e.g., powerpoint_presentation and word_document), or rmarkdown::render() can be called with different format arguments.
Question 2: A compliance officer asks for a documented record of every data transformation applied to a dataset. Which R approach best supports this requirement?
- A dplyr pipeline documented in an R Markdown file with narrative explanations (Correct answer)
- Transforming data in Excel before importing to R
- Saving intermediate CSVs at each step
- Using point-and-click GUI tools
Correct answer: A dplyr pipeline documented in an R Markdown file with narrative explanations
A documented dplyr pipeline in R Markdown creates a human-readable audit trail where each transformation step is visible, versioned, and reproducible.
Question 3: Which ggplot2 function call adds a clear, descriptive title and axis labels to a plot before sharing with stakeholders?
- labs(title = '...', x = '...', y = '...') (Correct answer)
- ggtitle() only
- xlab() and ylab() only
- annotate()
Correct answer: labs(title = '...', x = '...', y = '...')
labs() is the unified ggplot2 function for setting title, subtitle, caption, and all axis labels in a single, readable call.
Question 4: A product team is skeptical of a machine learning model's predictions. What communication artifact would most effectively build trust with technical skeptics?
- A detailed model card including training data description, performance metrics by subgroup, and known limitations (Correct answer)
- A marketing one-pager about the model
- The model's accuracy score alone
- A list of hyperparameters used
Correct answer: A detailed model card including training data description, performance metrics by subgroup, and known limitations
Model cards transparently document data sources, evaluation metrics, fairness considerations, and limitations, addressing technical stakeholders' core concerns.
Question 5: A Shiny dashboard is slow to respond when a stakeholder filters large data. Which optimization strategy should the analyst apply first?
- Move expensive computations outside reactive() into reactive({}) with bindCache() or pre-aggregate data (Correct answer)
- Add more RAM to the server
- Disable all reactive elements
- Switch to a different programming language
Correct answer: Move expensive computations outside reactive() into reactive({}) with bindCache() or pre-aggregate data
Caching results with bindCache() or pre-aggregating data before the app runs avoids repeating expensive computations on every user interaction.
Question 6: When a non-technical stakeholder says a chart is 'too busy,' which ggplot2 adjustment is the most direct fix?
- Apply theme_minimal() and reduce the number of geom layers or data series shown (Correct answer)
- Increase the plot dimensions
- Add more color
- Switch to a 3D chart
Correct answer: Apply theme_minimal() and reduce the number of geom layers or data series shown
theme_minimal() removes gridlines, borders, and background clutter, and reducing plotted series lowers cognitive load for non-expert viewers.
Question 7: A legal team requires that all analysis code used in a regulatory submission be preserved exactly as run. Which practice best satisfies this requirement?
- Tag a specific Git commit hash and store it with the submission package (Correct answer)
- Email the .R files to the legal team
- Print the code as a PDF
- Save the RStudio project folder as a ZIP
Correct answer: Tag a specific Git commit hash and store it with the submission package
A Git commit hash uniquely identifies an immutable snapshot of the codebase, providing a legally defensible, tamper-evident record of exactly what code was executed.
A stakeholder wants the same report delivered as both a slide deck and a Word document.
Which R Markdown output format supports multiple formats from one source file?