Making accessible data representation with maidr is easy and straightforward. If you already have data visualization code using ggplot2 or Base R, or, experimentally, lattice, you can make your plots accessible with maidr in just a few lines of code.
In an R Markdown or Quarto document, load the maidr package with library(maidr) in a setup chunk, as every page here does; nothing else is needed. From then on each plot the document draws comes out as an accessible chart in the page, whether a chunk returns it, prints it with print() or draws it with Base R. The same library(maidr) is all it takes at the console (see “How maidr hooks into your session” in the getting-started vignette). Documents written for earlier versions call maidr_on() in their setup chunk too; that still works, and is no longer needed. You can then explore each chart with the keyboard shortcuts below.
| Key | Action |
|---|---|
| Tab | Focus the chart; Shift + Tab leaves it |
| Left / Right | Move between data points |
| Up / Down | Move between series, stacked segments, heat map rows or box plot sections, on a chart that has them |
| Page Up / Page Down | Switch between the layers of a chart that has several |
| B | Toggle braille mode |
| T | Toggle text mode |
| S | Toggle sonification |
| R | Toggle review mode |
| C | Toggle high contrast mode |
| L, then X, Y or T | Announce the x axis label, the y axis label or the title |
| Space | Repeat the current sound |
| Ctrl + / (Cmd + / on macOS) | Show or hide the full keyboard shortcut help |
Every other shortcut, including autoplay, jumping to the ends, the command palette, settings and the AI chat, is on the MAIDR controls reference.
When to Use Each Plot Type
| Plot Type | Best For | Example Use Case |
|---|---|---|
| Bar Chart | Comparing categories | Sales by product |
| Pie Chart | Parts of a whole | Market share by brand |
| Histogram | Showing distributions | Test score frequencies |
| Scatter Plot | Relationships between variables | Height vs weight |
| Line Plot | Trends over time/order | Stock prices |
| Step Plot | Piecewise-constant state over time | A sleep-stage hypnogram |
| Box Plot | Distribution comparison | Salary by department |
| Violin Plot | Distribution shape comparison | Gene expression by group |
| Candlestick (OHLC) | Financial OHLC time-series | Stock price movements |
| Heatmap | Matrix relationships | Correlation matrices |
| Density | Smooth distributions | Probability density |
| Faceted | Comparing subgroups | Regional sales trends |
| Multi-Panel | Multiple related views | Dashboard layouts |
| Multi-Layered | Combining visualizations | Histogram + density overlay |
Examples by plot family
Each family page renders every example interactively, so you can explore the charts with the keyboard shortcuts above. The stable and experimental labels follow “Supported plot types” in the README: an experimental type is marked [experimental] after its name, and a type with no mark is stable. The stable families come first, and the experimental ones follow in a section of their own. Every example is also runnable locally: run_example() lists the scripts shipped with the package.
Stable plot families
- Bar, Pie and Word Cloud Examples: simple, dodged and stacked bar charts, pie charts, and the word cloud [experimental].
- Histogram, Density, Box and Violin Examples: the distribution family, including kernel density curves and violin plots.
- Scatter, Line, Step and Regression Examples: x-y plots, single and multi-line charts, hypnogram step plots and fitted regression lines.
- Heat Map and Candlestick Examples: matrix heat maps and OHLC candlestick charts, with the candlestick support matrix for ggplot2 and Base R.
-
Multi-Layered, Multi-Panel and Facet Examples: layered geoms, patchwork and
par(mfrow)layouts,facet_wrap()andfacet_grid().
Experimental plot families
These pages show only experimental types, which are prototypes: none has been through a user study, and each may change without a deprecation period, as “Experimental Plot Types” in the README explains.
- Base R Time-Series and Diagnostic Examples: correlograms [experimental], spectral density [experimental], cumulative periodograms [experimental], seasonal subseries [experimental], lag plots [experimental], partial effects [experimental] and Q-Q plots [experimental].
- Experimental Base R Chart Examples: biplots [experimental], radar charts [experimental], interaction plots [experimental], summary box plots [experimental], strip charts [experimental], dot charts [experimental], lollipops [experimental], mosaic and spine plots [experimental], conditional density [experimental], association plots [experimental], filled contours [experimental] and 100% stacked bars [experimental].
- lattice Chart Examples: bar charts [experimental], dodged and stacked bar charts [experimental], histograms [experimental], scatter plots [experimental], line and step plots [experimental], lollipops [experimental], box plots [experimental], heat maps [experimental], contour plots [experimental], density and smooth curves [experimental], dot plots [experimental], strip plots [experimental], Q-Q plots [experimental] and conditioned multi-panel charts [experimental]. Every chart maidr reads from lattice is experimental.