Created
August 14, 2018 18:34
-
-
Save sa-lee/c271b47d8065412d3d42c1ad8e63048d to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
library(nullabor) | |
library(gganimate) | |
library(magrittr) | |
p <- mtcars %>% | |
rorschach(method = null_permute("mpg"), n = 20, true = .) %>% | |
ggplot() + | |
geom_boxplot(aes(x = factor(cyl), y = mpg, fill = factor(cyl))) + | |
theme(legend.position = 'none', aspect.ratio = 1) + | |
xlab("cyl") | |
in_space <- p +facet_wrap(~.sample) | |
# ggsave("rorsach.png", in_space) | |
in_time <- p + transition_states(.sample, 3, 1) | |
animate(in_time, fps=8, width=400, height=400) | |
# anim_save(filename = "hop.gif") |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
For more info about visual inference see
http://rsta.royalsocietypublishing.org/content/367/1906/4361
For more info about hypothetical outcome plots see https://medium.com/hci-design-at-uw/hypothetical-outcomes-plots-experiencing-the-uncertain-b9ea60d7c740