knitr::opts_chunk$set( collapse = TRUE, comment = "#>" )
library(ntdice)
This is a package for experimenting with non-transitive dice.
Below is an example of how to get the matrix of probabilities, representing each pairing of dice.
# Get the grime dice set dice_g <- grime_dice() # Store Grime dice names ids_g <- c("Red", "Blue", "Olive", "Yellow", "Magenta") # Get the matrix of winning probabilities # Recall interpretation: each row's probability of beating a column wins_g <- get_win_matrix(dice_g, ids_g)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.