Making accessible data representation with maidr is easy and straightforward. If you already have data visualization code using ggplot2 or Base R, you can make your plots accessible with maidr in just a few lines of code.
Simply load the maidr package and call maidr_on(). When plots are printed in a document, maidr will automatically generate accessible versions. You can then interact with the accessible versions using keyboard shortcuts (refer to the table below).
| Key | Action |
|---|---|
| Left / Right | Navigate between data points |
| B | Toggle braille mode |
| T | Toggle text mode |
| S | Toggle sonification (hear the data) |
| R | Toggle review mode |
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.
- Bar, Pie and Word Cloud Examples: simple, dodged and stacked bar charts, pie charts, and the experimental word cloud.
- 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(). - Base R Time-Series and Diagnostic Examples: correlograms, spectral density, cumulative periodograms, seasonal subseries, lag plots, partial effects and Q-Q plots (experimental).
- Experimental Base R Chart Examples: biplots, radar charts, interaction plots, summary box plots, strip and dot charts, lollipops, mosaic and spine plots, conditional density, association plots, filled contours and 100% stacked bars (experimental).
Every example is also runnable locally: run_example() lists the scripts shipped with the package.