Want to share your content on R-bloggers? click here if you have a blog, or here if you don't.
datasauRus is a package storing the datasets from the paper Same Stats, Different Graphs: Generating Datasets with Varied Appearance and Identical Statistics through Simulated Annealing. It’s a useful package for:
- Having a dinosaur dataset
- Showing a dinosaur related variant of Anscombe’s Quartet
You can now get datasauRus on CRAN, though it might not be on all mirrors just yet.
install.packages("datasauRus")
Credit
This package wouldn’t exist without some nifty people:
- Alberto Cairo, datasaurus creator
- Justin Matejka and George Fitzmaurice, creator of the datasaurus’ friends
- Last but not least, Lucy McGowan who probably did more work on the package than I did
Examples
We’ve already started playing with the datasauRus dataset…
Me
library(ggplot2) library(datasauRus) ggplot(datasaurus_dozen, aes(x=x, y=y, colour=dataset))+ geom_point()+ theme_void()+ theme(legend.position = "none")+ facet_wrap(~dataset, ncol=3)
Ramnath
library(ggplot2) library(datasauRus) library(gganimate) p <- ggplot(datasaurus_dozen, aes(x = x, y = y, frame = dataset)) + geom_point() + theme(legend.position = "none") gganimate(p, title_frame = FALSE)
In the package
Every dataset has an example associated with it. These can be found not just in the help files for each dataset but also in a standalone directory (inst/examples
). We’d like to keep building on these so please feel free to add any visualisations you make with the datasets. If you haven’t worked on a package before and want some help, you can book some time with me to get your dataviz example into the package.
The post datasauRus now on CRAN appeared first on Locke Data. Locke Data are a data science consultancy aimed at helping organisations get ready and get started with data science.
R-bloggers.com offers daily e-mail updates about R news and tutorials about learning R and many other topics. Click here if you're looking to post or find an R/data-science job.
Want to share your content on R-bloggers? click here if you have a blog, or here if you don't.