Contains functions for the easy display of statistical tests as well as some convenience functions for data cleanup. It is meant to ease existing workflows with packages like 'sjPlot', 'dplyr', and 'ggplot2'. The primary components are the functions prefixed with 'tadaa_', which are built to work in an interactive environment, but also print tidy markdown tables powered by 'pixiedust' for the creation of 'RMarkdown' reports.
This is tadaatoolbox version 0.10.0
(semver).
It contains helpers for data analysis and presentation focused on undergrad psychology, the target audience being students at University of Bremen.
Please consider this as a teaching project and be careful if you intend to use it for production use.
To see what's new, see NEWS.md.
As a sideproject, I attempted to visualize the package depencencies in this document. It's not optimal yet, but at least it's a glimpse of the first two layers of dependencies.
Install the current development version from GitHub (recommended):
if (!("devtools" %in% installed.packages())){
install.packages("devtools")
}
devtools::install_github("tadaadata/tadaatoolbox")
Or install the most recent stable version from CRAN:
install.packages("tadaatoolbox")
Please do! I have no idea where I'm going with this. Feel free to open issues.
Contributer | Role |
---|---|
Lukas Burk | aut & cre |
Tobias Anton | aut |
Daniel Lüdecke | ctb |
See the included vignette for a demonstration: browseVignettes("tadaatoolbox")
or view the current version in this repository via GitHubs HTML preview.
modus
: A simple function to extract the mode of a frequency table
nom_chisqu
: Simple wrapper for chisq.test
that produces a single value.
nom_phi
: Simple wrapper for vcd::assocstats
to extract phi.
nom_v
: Simple wrapper for vcd::assocstats
to extract Cramer's V.
nom_c
: Simple wrapper for vcd::assocstats
to extract the contingency coefficient c.
nom_lambda
: Simple wrapper for ryouready::nom.lambda
to extract appropriate lambda.
ord_gamma
: Simple wrapper for ryouready::ord.gamma
.
ord_somers_d
: Simple wrapper for ryouready::ord.somers.d
.
tadaa_nom
: All the nominal stats in one table.
tadaa_ord
: All the ordinal stats in one table.
tadaa_sem
: Standard error and CI, you guessed it, in one table.
generate_recodes
: To produce recode assignments for car::recode
for evenly sequenced clusters.interval_labels
: To produce labels for clusters created by cut
.tadaa_likertize
: Reduce a range of values to n
classes (methodologically wonky).delet_na
: Customizable way to drop NA
observations from a dataset.labels_to_factor
: If you mix and match sjPlot
, haven
and ggplot2
, you might need to translate labels
to factors
, which is precisely what this functions does. Drop in data.frame
with label
, receive data.frame
with factors
.drop_labels
: If you subset a labelled
dataset, you might end up with labels that have no values with them. This function will drop the now unused labels
.pval_string
: Shamalessly adapted from pixiedust::pvalString
, this will format a p-value as a character string in common p < 0.001
notation and so on. The difference from the pixiedust
version is that this function will also print p < 0.05
.tadaa_aov
: For aov
with included partial eta^2.tadaa_t.test
: For t.test
with automatic homogenity of variance detection, effect size and power.tadaa_normtest
lets you do tests for normality (4 methods) over multiple variables.mean_ci_t
: Returns a data.frame
with y
(mean
), ymin
and ymax
for the CI bounds.
confint_t
: For the underlying function to get the CI width. Returns a single value.tadaa_int
: Simple interaction plot template.tadaa_heatmap
: Simple heatmap template.tadaa_normtest
lets you do tests for normality (4 methods) over multiple variables.tadaa_heatmap
generates a heatmap. Mhhh, heatmaps.tadaa_sem
shows the standard error of the mean and it's confidence intervalpval_string
as a modification of pixiedust::pvalString
that includes p < .05
.tadaa_aov
, tadaa_t.test
and the new tadaa_normtest
now return a data.frame
by default, allowing further shenaniganstadaa_int
:
grid = TRUE
for the two interaction plots to be printen in a grid via
cowplot::plot_grid.labels
argument.tadaa_int
plot output now also is a little tidier and optimized for smaller widths.tadaa_aov
now also shows Cohen's f for easier power calculations based on f (pwr
, G*power)reduce
to modus
, so multiple results will be concatenated to a character by default.as_character
to modus
because guessing about return value classes is no joke.generate_recodes
and interval_labels
(#1).tadaa_ord
as ordinal equivalent of tadaa_nom
.brewer_palette
option to tadaa_int
DESCRIPTION
are still experimental because of uncertainty regarding failing travis builds. I don't know what's going on there.family
tag to tadaa_
functions so their documentation is linkedtadaa_aov
, _t.test
and _nom
which did not work as I expectedDESCRIPTION
, misspelling pixiedust
. Sorry!pixiedust
depends on R (>= 3.2.1), so we might as well depend on that version, toopixiedust
, sjmisc
, and broom
, just to be safeREADME
to be less redundant compared to the usage vignetteNEWS.md
file to track changes to the package.