Week 5: Documentation and reports

1. A data analyst wants to create documentation for their cleaning process so other analysts on their team can recreate this process. What tool can help them create this shareable report?

  • Code chunks
  • Inline code
  • Dashboards
  • R Markdown

2. A data analyst wants to export their R Markdown notebook as a text document. What are the text document formats they can use to share their R Markdown notebook? Select all that apply.

  • Notepad
  • Word
  • PDF
  • HTML

3. A data analyst writes two hashtags next to their header. What will this do to the header font in the .rmd file?

  • Make it bigger
  • Make it smaller
  • Make it centered
  • Make it a different color

4. Fill in the blank: A data analyst includes _____ in their R Markdown notebook so that they can refer to it directly in their explanation of their analysis.

  • inline code
  • markdown
  • markdown
  • documentation

5. What symbol can be used to add bullet points in R Markdown?

  • Asterisks
  • Brackets
  • Exclamation marks
  • Backticks

6. A data analyst adds a section of executable code to their .rmd file so users can execute it and generate the correct output. What is this section of code called?

  • Data plot
  • Documentation
  • YAML
  • Code chunk

7. A data analyst is inserting a line of code directly into their .rmd file. What will they use to mark the beginning and end of the code?

  • Delimiters
  • Asterisks
  • Markdown
  • Hashtags

8. A data analyst who works with R creates a weekly sales report by remaking their .rmd file and converting it to a report. What can they do to streamline this process?

  • Create an R notebook
  • Knit their .rmd file
  • Convert their .rmd file
  • Create a template

9. R Markdown is a file format for making dynamic documents with R. What are the benefits of creating this kind of document? Select all that apply.

  • Save, organize, and document code
  • Create a record of your cleaning process
  • Perform calculations for analysis more efficiently
  • Generate a report with executable code chunks

10. A data analyst wants to change their header to be one font size smaller. What should they add to their markdown syntax?

  • Backtick
  • Exclamation mark
  • Double space
  • Hashtag

11. A data analyst wants to include a line of code directly in their .rmd file in order to explain their process more clearly. What is this code called?

  • YAML
  • Markdown
  • Documented
  • Inline code

12. Which sample correctly implements a code chunk in a .rmd file?

  • value <- 8

  • “`{r}

    value <- 8

    “`

  • ###

    value <- 8

     

  • “`{!}

    value <- 8

    “`

13. What type of export document should you use while you are working and don’t need to worry about adding page breaks in the correct places?

  • HTML
  • YAML
  • PDF
  • Word

14. What are the benefits of working with R Markdown? Select all that apply.

  • R Markdown runs interactive code chunks.
  • R Markdown runs R code faster.
  • R Markdown makes it possible to use larger datasets.
  • R Markdown allows styled text between code. (=)

15. A data analyst wants to change the default file format that gets exported by the Knit button to .pdf. What field of the YAML header should they change to set the new default file format?

  • export
  • title
  • output
  • author

16. A data analyst is reading through an R Markdown notebook and finds the text _this_ is important. What is the purpose of the underscore characters in this text?

  • They add the text as an image caption
  • They wrap the text in a clickable link
  • They style the text as bold
  • They style the text as italics

17. A data analyst works with an .rmd file in RStudio and wants the ability to quickly find a code chunk using the label “analysis”. Which code example would allow the analyst to quickly access the code chunk using this label?

  • “`{analysis r}
  • “`analysis{r}
  • “`{r analysis}
  • “`{r} analysis

18. Fill in the blank: A delimiter is a character that indicates the beginning or end of _____.

  • a data item
  • an analysis
  • a section
  • a header

19. Fill in the blank: R Markdown notebooks can be converted into HTML, PDF, and Word documents, slide presentations, and _____.

  • dashboards
  • tables
  • YAML
  • spreadsheets

20. Which code snippet implements the correct syntax for writing a piece of hyperlinked text in markdown?

  • link**www.coursera.com
  • (link)[www.coursera.com]
  • [link](www.coursera.com )
  • >link–www.cousera.com<

21. What is the purpose of the Knit button in R Studio?

  • It combines multiple .rmd files into a single file.
  • It imports the content from a .rmd file.
  • It creates a new .rmd file.
  • It exports the .rmd file to another document type.

22. A data analyst wants to make a word in their markdown stand out by making it bold. What characters should they surround the text with to achieve the bold style?

  • Angle brackets (<>)
  • Double asterisks (**)
  • Double hashtag (##)
  • Single asterisk (*)

23. A data analyst is working in a .rmd file and comes across the text ```{r analysis}. What is the purpose of the text “analysis”?

  • It is a label for the code chunk
  • It changes the way the code gets exported
  • It runs the code in analysis mode
  • It alters the output file format of Knit

24. Why would a data analyst create a template of their .rmd file? Select all that apply.

  • To create an interactive notebook
  • To prevent other users from editing the file
  • To customize the appearance of a final report
  • To save time when creating the same kind of document

25. A data analyst wants to perform an analysis and make it easy for colleagues to understand his process and update the analysis a year from now. Which tool is best to achieve this objective?

  • Code chunks
  • R Markdown
  • PDF document
  • Word Document

26. A data analyst needs to create a shareable report in RStudio. They first want to change the default file format that gets exported by the Knit button to .pdf. What value should they use for the output field in the YAML header?

  • pdf_knit
  • pdf_document
  • document_pdf
  • knit_pdf

27. What does the ```{r} delimiter (three backticks followed by an r contained inside curly brackets) indicate in an R Markdown notebook?

  • The start of YAML metadata
  • The end of a code chunk
  • The end of YAML metadata
  • The start of a code chunk

28. A data analyst notices that their header is much smaller than they wanted it to be. What happened?

  • They have too few asterisks
  • They have too many hashtags
  • They have too few hashtags
  • They have too many asterisks

29. Fill in the blank: _____ code is code that can be inserted directly into a .rmd file.

  • Executable
  • Markdown
  • Inline
  • YAML

30. Fill in the blank: If an analyst creates the same kind of document over and over or customizes the appearance of a final report, they can use _____ to save them time.

  • a filter
  • a code chunk
  • an .rmd file
  • a template

31. Which combination of text characters can be used to embed an image in a markdown document?

  • ![]()
  • ##
  • <>
  • *[]()

32. When you Knit a file in RStudio what part of code chunks are shown by default?

  • The delimiter
  • The output
  • The YAML
  • The code

33. A data analyst comes across in a piece of markdown text. What effect do the angle brackets () have on the inner text?

  • They create a piece of inline code
  • They create a clickable link
  • They create a bullet list
  • They create bold text

34. Fill in the blank: Code added to an .rmd file is usually referred to as a code _____. This allows users to execute R code from within the .rmd file.

  • chunk
  • section
  • file
  • filter

35. You finish working with an R Markdown notebook and now you need to distribute your work. How can you export your analysis as a styled report?

  • chunk
  • section
  • file
  • filter

36. You finish working with an R Markdown notebook and now you need to distribute your work. How can you export your analysis as a styled report?

  • Use two hashtags
  • Use the Knit Button
  • Use the Contents Menu
  • Use markdown text

37. Which pieces of markdown text will produce a result that is italicized? Select all that apply.

  • *text*
  • _text_
  • * text
  • **text**

38. A data analyst includes a code chunk in their .rmd file. What does this allow other users to do? Select all that apply.

  • Copy code directly from the .rmd file
  • Execute code directly from the .rmd file
  • Undo original project code directly from the .rdm file
  • Modify code directly from the .rmd file

39. A data analyst is regularly exporting documents from a .rmd file and manually customizing the appearance of the document they give to stakeholders. What would allow them to automatically customize the appearance of the document?

  • A template
  • A YAML header
  • An inline code snippet
  • A delimiter

40. A data analyst comes across in a piece of markdown text. What effect do the angle brackets () have on the inner text?

  • They create a clickable link
  • They create bold text
  • They create a piece of inline code
  • They create a bullet list

41. What delimiter is used to indicate the YAML metadata in an R Markdown notebook?

  • “`{r}
  • ###
  • “`
  • (This is the answer)

Leave a Reply