Show the code
library(plotly)
plot_ly(
data = iris,
x = ~Sepal.Length,
y = ~Petal.Length,
color = ~Species,
type = "scatter",
mode = "markers"
)PSI AIMS
September 17, 2026
The September Open-Source Lunch Bites session introduced Quarto, an open-source scientific and technical publishing system from Posit. Quarto provides a practical way to bring code, analytical output and narrative together in a single reproducible document.
For analysts and programmers working in the pharmaceutical industry, this can help close the gap between doing the analysis and communicating the analysis. Rather than running code, exporting results and then manually copying tables, figures or numbers into another application, Quarto allows the analysis and the document that presents it to live together.
We started with the basic structure of a .qmd file and the three main ingredients:
From a simple HTML document, the examples then built up to include interactive Plotly graphics and DT data tables.
We also looked at Quarto dashboards. Starting with a simple column layout, the examples progressively added analytical outputs, linked filtering with Crosstalk, sidebars, navigation, tabs and custom styling. This provides a useful middle ground for situations where some interactivity is valuable but a full reactive application is unnecessary.
Finally, we looked at a clinical-trial reporting example combining demographics and adverse-event summaries, figures and narrative text. A particularly useful feature is the ability to place calculated values directly into the narrative. When the underlying data or analysis changes, re-rendering the document can update the narrative, tables and figures together.
Quarto does not replace tools such as R, Python, ggplot2, Plotly or DT. Instead, it provides a framework in which their outputs can be organised, explained and published.
The presentation and runnable Quarto examples from the session are available in the PSI AIMS GitHub repository:
Open-Source Lunch Bites — Quarto Basics: slides and examples
The examples progress from a first Quarto document through interactive analytical output and several dashboard layouts, so they can also be used as a starting point for experimenting with Quarto yourself.
For more information about Quarto, visit the Quarto website.
There is a practical example of Quarto right here: the PSI AIMS website itself. The website is built from multiple .qmd files, and this article is one of them.
A Quarto page can mix ordinary narrative with analytical output. For example, an interactive Plotly figure can sit directly alongside the text:
The output is interactive, while the R code is tucked away until a reader chooses Show the code.
The same idea works for data. Here is a small interactive DT table with sorting, paging and column filters:
So a single .qmd can contain narrative, figures, interactive data and the code that generates them. When the data or analysis changes, re-rendering the page refreshes the published output rather than requiring results to be copied and pasted manually.
Explore the Quarto Basics slides and runnable examples, or take a look at the source for the PSI AIMS website.