Week 7 Exercises - Quarto, LaTeX Math, and AI Assistants

Short, ungraded practice tasks - about 30 minutes. Companion reading: Ch. 16, Ch. 17, and Ch. 18. These tasks build the skills your final project write-up needs - start that write-up as a .qmd this week, using the three in-class demo files on the Example Files page as skeletons (the manuscript example is the intended starting point for the project report).

  1. In Positron, create a new Quarto document (Command Palette → Quarto: New Document), give it a title and your name in the YAML header, and render it to HTML (Cmd/Ctrl+Shift+K).
  2. Add an R code chunk that reads the stickleback data and prints dim(stickle). Render again.
  3. Add a chunk that makes one ggplot figure, with a label and fig-cap chunk option, and render.
  4. Hide the code of the figure chunk with echo: false - the figure should remain.
  5. Add inline math (a mean, $\bar{x}$) and one display equation (e.g., the standard error) between $$ fences.
  6. Add a callout block (::: {.callout-note}) with a note to your future self.
  7. Cross-reference your figure from the text with @fig-....
  8. Add citations: create a references.bib next to your document with one entry (Google Scholar → Cite → BibTeX is the quickest source), add bibliography: references.bib to your YAML header, and cite the entry in a sentence with @its-key. Render - the formatted citation and an automatic reference list should both appear.
  9. Restart R, clear everything, and render one more time: does the document run cleanly from scratch? (If not, something lives only in your console - fix that.)
  10. If you have TinyTeX installed, switch format: html to format: pdf and render. Read the error log if it fails - what is it asking for?
  11. Take one error message you hit this week, paste it into an AI assistant, and ask for an explanation. Then verify the explanation against the documentation. Where was it right, incomplete, or wrong?
  12. Ahead of Week 10 (Talapas): confirm your cluster account works - log in to Open OnDemand at https://ondemand.talapas.uoregon.edu with your Duck ID. If you cannot get in, contact me now, not in Week 10.
  13. HW1 is also due next Monday, November 16 - both questions. Dry-run Question 2 the way it will be graded: copy your project folder somewhere else and run the script from the project top. If relative paths are doing their job, it just works.