Learn R Programming

nullabor: lineup and Rorschach plots for visual inference

Di Cook, Hadley Wickham, Niladri Roy Chowdhury, Heike Hofmann, Mans Thulin November 29, 2024

nullabor

Tools for graphical inference: prevent fooling yourself with the Rorschach protocol and check the surprising features in your data with the lineup protocol!

Installation

The nullabor package can be installed from CRAN

install.packages("nullabor")

You can install the development version of nullabor from github with:

# install.packages("devtools")
devtools::install_github("dicook/nullabor")

Copy Link

Version

Install

install.packages('nullabor')

Monthly Downloads

3,113

Version

0.3.16

License

GPL (>= 2)

Issues

Pull Requests

Stars

Forks

Maintainer

Di Cook

Last Published

September 26th, 2026

Functions in nullabor (0.3.16)

pvisual

P-value calculations.
sep_dist

Distance based on separation of clusters
resid_rotate

Rotation residuals.
theme_strip

A theme to minimally strip away the context
tips

Tipping data
reg_dist

Distance based on the regression parameters
sample_size

Sample size calculator
resid_sigma

Residuals simulated by a normal model, with specified sigma
null_permute

Generate null data by permuting a variable.
rorschach

The Rorschach protocol.
turk_results

Sample turk results
uni_dist

Distance for univariate data
resid_boot

Bootstrap residuals.
resid_pboot

Parametric bootstrap residuals.
visual_power

Power calculations.
lal

Los Angeles Lakers play-by-play data.
null_ts

Generate null data by simulating from a time series model.
wasps

Wasp gene expression data.
opt_bin_diff

Finds the number of bins in x and y direction which gives the maximum binned distance.
add_true

Add true data into data frame containing null data sets.
box_dist

Distance based on side by side Boxplots
decrypt

Use decrypt to reveal the position of the real data.
calc_diff

Calculating the difference between true plot and the null plot with the maximum distance.
bin_dist

Binned Distance
distplot

Plotting the distribution of the distance measure
electoral

Polls and election results from the 2012 US Election
distmet

Empirical distribution of the distance
aud

Conversion rate of 1 Australian Doller (AUD) to 1 US Dollar
calc_mean_dist

Calculating the mean distances of each plot in the lineup.
null_lm

Generate null data with null residuals from a model.
lineup

The line-up protocol.
null_dist

Generate null data with a specific distribution.
lineup_qq

Check distributional assumptions using Q-Q plots and the lineup protocol.
lineup_residuals

Compare residual plots of a fitted model to plots of null residuals.
null_gen

Computing th distance for the null plots
find_plot_data

Find plot data. If data is not specified, this function will attempt to find the data corresponding to the last ggplot2 created or displayed. This will work in most situations where you are creating the plot and immediately displaying it, but may not work in other situations. In those cases, please specify the data explicitly.
lineup_histograms

Check distributional assumptions using histograms and the lineup protocol.
resid_perm

Permutation residuals.