### Quarto Code Block Options You can manually type out code blocks (chunks): ``` ```{r} ``` ```{r} #| echo: false #| fig-cap: "Air Quality" ``` ``` ``` ```{r} #| label: car-cyl #| echo: false mtcar %>% distinct(cyl) ``` >[!Quarto Code Block Options] > Code block options are included in a special comment at the top of the block (lines at the top prefaced with `#|` are considered options). In Quarto, code block options go _below_ the curly braces not within the braces. Each option goes on its own line preceded by a pound sign and vertical "pipe" character (i.e., #| ), such as ``` {r} #| label: code_block #| echo: false #| output: false #| fig-cap: figure caption ``` >[!Difference from R Markdown] > The code block options in Quarto are different from R Markdown which includes the code block (chunk) options within the curly braces. Code block options available in Quarto for customizing output include: **<u>Option</u>** **<u>Description</u>** `eval` Evaluate the code chunk (if `false`, only echoes the code into the output). (`true`, `false`) `echo` Include the source code in output. (`true`, `false`) `output` Include the results of executing the code in the output to indicate that the output is raw markdown and should not have any of Quarto’s standard enclosing markdown). (`true`, `false`, or `asis`) `warning` Include warnings in the output. (`true`, `false`) `error` Include errors in the output (note that this implies that errors executing code will not halt processing of the document). (`true`, `false`) `include` Catch all for preventing any output (code or results) from being included (e.g. `include: false` suppresses all output from the code block). (`true`, `false`) *** 2023 cloudedknowledge.net