Skip to contents

Hypothesis tests

Wrapper functions for common statistical tests used in introductory courses, with output designed to be readable by beginners.

oneSampleTTest()
One sample t-test
independentSamplesTTest()
Independent samples t-test
pairedSamplesTTest()
Paired samples t-test
associationTest()
Chi-square test of association / independence
goodnessOfFitTest()
Chi-square goodness of fit test
posthocPairwiseT()
Post-hoc pairwise t-tests for ANOVA
print(<TTest>)
Print t-test results
print(<assocTest>)
Print chi-square association test results
print(<gofTest>)
Print goodness of fit test results

Effect sizes and descriptive statistics

Functions for computing effect sizes and summarising data, intended as companions to the hypothesis test functions above.

cohensD()
Cohen's d
etaSquared()
Effect size for ANOVAs
cramersV()
Cramer's V
ciMean()
Confidence interval around the mean
correlate()
Correlation matrices
print(<correlate>)
Print correlation matrix results

Data manipulation

Functions for reshaping, reordering, and recoding data frames and factors.

wideToLong()
Reshape from wide to long
longToWide()
Reshape from long to wide
expandFactors()
Expand factors to a set of contrasts
permuteLevels()
Permute the levels of a factor
quantileCut()
Cut by quantiles
sortFrame()
Sort a data frame
tFrame()
Transpose a data frame
colCopy() rowCopy()
Copy a vector into a matrix

Visualisation

A simple plotting function for displaying frequency and proportion data as bar charts.

bars()
Grouped bar plots with error bars

Workspace utilities

Helper functions for inspecting and managing the R workspace, and for miscellaneous statistical tasks not covered elsewhere.

who()
Contents of workspace
modeOf() maxFreq()
Sample mode
aad()
Mean absolute deviation
rmAll()
Remove all objects from the workspace
unlibrary()
Unload a package
importList()
Import a list into the workspace
standardCoefs()
Standardised regression coefficients
print(<whoList>)
Print workspace summary