• Stars
    star
    752
  • Rank 57,989 (Top 2 %)
  • Language
    R
  • License
    GNU General Publi...
  • Created almost 4 years ago
  • Updated about 2 months ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

Visualizations of distributions and uncertainty

ggdist: Visualizations of distributions and uncertainty

R build status Coverage status CRAN status Download count DOI

Preview of ggdist plots

ggdist is an R package that provides a flexible set of ggplot2 geoms and stats designed especially for visualizing distributions and uncertainty. It is designed for both frequentist and Bayesian uncertainty visualization, taking the view that uncertainty visualization can be unified through the perspective of distribution visualization: for frequentist models, one visualizes confidence distributions or bootstrap distributions (see vignette("freq-uncertainty-vis")); for Bayesian models, one visualizes probability distributions (see the tidybayes package, which builds on top of ggdist).

The geom_slabinterval() / stat_slabinterval() family (see vignette("slabinterval")) makes it easy to visualize point summaries and intervals, eye plots, half-eye plots, ridge plots, CCDF bar plots, gradient plots, histograms, and more:

The slabinterval family of geoms and stats

The geom_dotsinterval() / stat_dotsinterval() family (see vignette("dotsinterval")) makes it easy to visualize dot+interval plots, Wilkinson dotplots, beeswarm plots, and quantile dotplots (and combined with half-eyes, composite plots like rain cloud plots):

The geom_lineribbon() / stat_lineribbon() family (see vignette("lineribbon")) makes it easy to visualize fit lines with an arbitrary number of uncertainty bands:

All stat in ggdist also support visualizing analytical distributions and vectorized distribution data types like distributional objects or posterior::rvar() objects. This is particularly useful when visualizing uncertainty in frequentist models (see vignette("freq-uncertainty-vis")) or when visualizing priors in a Bayesian analysis.

The ggdist geoms and stats also form a core part of the tidybayes package (in fact, they originally were part of tidybayes). For examples of the use of ggdist geoms and stats for visualizing uncertainty in Bayesian models, see the vignettes in tidybayes, such as vignette("tidybayes", package = "tidybayes") or vignette("tidy-brms", package = "tidybayes").

Cheat sheets

Installation

You can install the currently-released version from CRAN with this R command:

install.packages("ggdist")

Alternatively, you can install the latest development version from GitHub with these R commands:

install.packages("devtools")
devtools::install_github("mjskay/ggdist")

Feedback, issues, and contributions

I welcome feedback, suggestions, issues, and contributions! I am not particularly reliable over email, though you can contact me at [email protected]. On Twitter I am more reliable. If you have found a bug, please file it here with minimal code to reproduce the issue. Pull requests should be filed against the dev branch.

Citing ggdist

Matthew Kay (2023). ggdist: Visualizations of Distributions and Uncertainty. R package version 3.3.0, https://mjskay.github.io/ggdist/. DOI: 10.5281/zenodo.3879620.

More Repositories

1

tidybayes

Bayesian analysis + tidy data + geoms (R package)
R
700
star
2

ggblend

Support for blend modes in ggplot2
R
160
star
3

uncertainty-examples

Uncertainty visualization examples
HTML
106
star
4

ARTool

R Package for Aligned Rank Transform for Nonparametric Factorial ANOVAs
R
51
star
5

when-ish-is-my-bus

Data and code for "When (ish) is My Bus? User-centered Visualizations of Uncertainty in Everyday, Mobile Predictive Systems" (CHI 2016)
R
45
star
6

election-galton-board

Plinko boards for the 2020 US Presidential election predictions
HTML
28
star
7

tidybayes.rethinking

R package to allow tidybayes to work with the rethinking package
R
25
star
8

uncertainty-vis-course

24
star
9

uncertainty-vis-book

Uncertainty Visualization book
TeX
20
star
10

gender-in-image-search

Data and analysis of unequal representation and gender stereotypes in image search results for occupations
HTML
18
star
11

by_row

A proposal for an alternative to rowwise() and mutate() + map()
9
star
12

ggbuilder

An (experimental) alternative way to build ggplot layers
R
6
star
13

acceptability-of-accuracy

Code for generating surveys and fitting models of acceptability of accuracy
CSS
6
star
14

wordle_solver

A simple solver for Wordles
5
star
15

ggdist-paper

Source and supplement for the ggdist paper
HTML
5
star
16

explodeAssign

Explode assignment operators for R
R
4
star
17

plinko

Animated plinko boards in R
R
4
star
18

bayes-for-chi

Data and code for "Researcher-Centered Design of Statistics: Why Bayesian Statistics Better Fit the Culture and Incentives of HCI" (CHI 2016)
R
4
star
19

dots

Copy ellipsis arguments from one set of functions to a wrapper function in R
R
2
star
20

metroidvania-ranks

2
star
21

linear-in-probit

Linear in probit subjective probability transformations
1
star
22

vax

1
star
23

gatherplots-data

Recreation of charts from the gatherplots paper
HTML
1
star
24

bayes_plots

1
star