All eight analysis functions return an object of class
anovakit_fit. It is a plain list, so $ extraction works as
usual, with print, summary and plot methods for
convenience.
Components
- method
Character. The analysis that was run, as printed.
- call
The matched call, so a result can always say how it was made.
- model
The fitted model object: an
lmfromanova_ancova, aglm(or anegbinfromMASS::glm.nb()) fromanova_bin,anova_countandanova_glm, the multivariatemlmfromanova_manova, anafex_aovfromanova_rm(fitted on internal names, see its$internal_names), and thehtestreturned byoneway.testorkruskal.testfromanova_welchandanova_kw, which fit no model. The call of a fittedlmorglmreaches the analysed rows from anywhere, soupdate(),step()andlmtest::lrtest()work on it directly: for instanceupdate(fit$model, . ~ 1).- anova
Data frame. The omnibus test table. Its attributes record the type of sums of squares, the test statistic and (in
anova_rm) the sphericity correction;print()shows them.- effect_sizes
Data frame, or
NULL. What it holds depends on the method: partial eta squared with partial omega squared (anova_ancova,anova_manova, andanova_glmon a Gaussian family), a standardised mean difference on the average of the two group variances, with intervals (anova_welch), epsilon squared and eta squared for the rank statistic (anova_kw), partial and generalised eta squared (anova_rm), odds ratios (anova_bin) and incidence rate ratios (anova_count), each a level against its reference level whatever the contrasts, and the deviance explained (anova_glmon any other family) with McFadden's pseudo R squared for the binomial, Poisson and negative binomial families only. Both variance measures are partial: the classical omega squared is only a proportion of variance when the effect sums of squares partition the total, which Type II and Type III sums of squares do not.- emmeans
Data frame, or
NULL. Estimated marginal means with intervals atconf_level(group summaries foranova_welchandanova_kw). When grouping factors enter a model additively they are reported per factor, with atermcolumn.- emmeans_object
The
emmGrid, a named list of them (one per factor) when the means are reported per factor, orNULL. Pass it to emmeans for contrasts the wrapper does not cover. It carries emmeans' own default confidence level rather thanconf_level, so givelevel =when you summarise it. It isNULLforanova_welchandanova_kw, which fit no model emmeans can use, and foranova_manova, where there is one grid per response under$univariate[[response]]$emmeans_object.- posthoc
Data frame, or
NULL. Pairwise comparisons, with the unadjusted p-value inp_value, the adjusted one inp_adjustedand the method inadjustment.- assumptions
Named list of assumption checks. Contents vary by method; each element is a test object, a data frame or
NULL. It is empty foranova_kwunlessdiagnostics = TRUE, since the test assumes no distribution.- plots
Named list of ggplot2 objects. Empty when
plots = FALSE. Nothing is ever drawn as a side effect.- data_used
Data frame. The rows and columns the model was fitted on: the analysed columns only, after missing and infinite values, zero weights and incomplete subjects are removed. Covariates are mean-centred there when
anova_ancovaoranova_manovacentred them.- n_removed
Integer. Input rows that are not in
data_used: dropped for missing or infinite values (a factor level that is itselfNAcounts as missing) or a prior weight of zero, or, inanova_rm, for an incomplete within-subject design or because repeated subject-by-cell rows were aggregated (withfun_aggregate, the mean by default).nrow(data_used) + n_removedis always the number of rows given.- conf_level
Numeric. The level used for every interval returned.
- notes
Character vector. Everything the function decided on your behalf, could not compute, or thinks you should know – including anything car,
glm, emmeans, sandwich or afex said while the model was being fitted. Always read this.
Components individual functions add
Each function returns everything above plus whatever its own method
produces. names(fit) lists them all. anova_ancova adds
$slopes_test, $simple_slopes, $covariate_means,
$model_additive and $model_interaction;
anova_rm adds $sphericity, $subjects_dropped,
the breakdown of $n_removed, $residuals (within-subject
residuals in the row order of $data_used) and
$internal_names; anova_manova adds
$multivariate, $univariate, $canonical,
$canonical_term, $slopes_test (with covariates),
$covariate_means and $test; anova_count adds
$model_type, $dispersion and $model_dispersion;
anova_bin adds $model_stats; anova_glm
adds $model_stats and $family. Each is documented on the
function that produces it.