A couple of weeks ago I wrote a blog post about
slopegraphs. There was some
polite interest and it was a good chance to practice my functional
programming skills so
I decided to see if I could make a decent R function from what I had
learned. It’s in pretty good shape so I just pushed an update to
CRAN (it will take awhile to process). You can also get the latest version from GitHub.
The package also includes other functions that I find useful for teaching
statistics as well as actually practicing the art. They typically are
not “new” methods but rather wrappers around either base R or other
packages and concepts I’m trying to master.
Plot2WayANOVAwhich as the name implies conducts a 2 way ANOVA and
plots the results using
PlotXTabswhich as the name implies plots cross tabulated
newetawhich is a helper function that appends the results of a
Type II eta squared calculation onto a classic ANOVA table
Modewhich finds the modal value in a vector of data
SeeDistwhich wraps around ggplot2 to provide visualizations of
OurConfis a simulation function that helps you learn about
<span class="c1"># Install from CRAN</span><span class="w"> </span><span class="n">install.packages</span><span class="p">(</span><span class="s2">"CGPfunctions"</span><span class="p">)</span><span class="w"> </span><span class="c1"># Or the development version from GitHub</span><span class="w"> </span><span class="c1"># install.packages("devtools")</span><span class="w"> </span><span class="n">devtools</span><span class="o">::</span><span class="n">install_github</span><span class="p">(</span><span class="s2">"ibecav/CGPfunctions"</span><span class="p">)</span><span class="w"> </span>
Many thanks to Dani Navarro and the book > (Learning Statistics with
whose etaSquared function was the genesis of
“He who gives up safety for speed deserves neither.”
A shoutout to some other packages I find essential.
- stringr, for strings.
- lubridate, for date/times.
- forcats, for factors.
- haven, for SPSS, SAS and Stata
- readxl, for
- modelr, for modelling within a
- broom, for turning models into
- ggplot2, for data visualisation.
- dplyr, for data manipulation.
- tidyr, for data tidying.
- readr, for data import.
- purrr, for functional programming.
- tibble, for tibbles, a modern
re-imagining of data frames.
If you like CGPfunctions, please consider leaving feedback
Contributions in the form of feedback, comments, code, and bug reports
are most welcome. How to contribute:
- Issues, bug reports, and wish lists: File a GitHub
- Contact the maintainer ibecav at gmail.com by email.