ez_anova: Analysis of variance

Description Usage Arguments Value Examples

Description

This is wrapper to the ez::ezANOVA() function.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
ez_anova(
  data,
  dv,
  wid,
  within = NULL,
  within_full = NULL,
  within_covariates = NULL,
  between = NULL,
  between_covariates = NULL,
  observed = NULL,
  diff = NULL,
  reverse_diff = FALSE,
  type = 2,
  white.adjust = FALSE,
  detailed = FALSE,
  return_aov = FALSE
)

Arguments

data

Data frame containing the data to be analyzed.

dv

Name of the column in data that contains the dependent variable. Values in this column must be numeric.

wid

Name of the column in data that contains the variable specifying the case/Ss identifier. This should be a unique value per case/Ss.

within

Names of columns in data that contain predictor variables that are manipulated (or observed) within-Ss.

within_full

Same as within, but intended to specify the full within-Ss design in cases where the data have not already been collapsed to means per condition specified by within and when within only specifies a subset of the full design.

within_covariates

Names of columns in data that contain predictor variables that are manipulated (or observed) within-Ss and are to serve as covariates in the analysis.

between

Names of columns in data that contain predictor variables that are manipulated (or observed) between-Ss.

between_covariates

Names of columns in data that contain predictor variables that are manipulated (or observed) between-Ss and are to serve as covariates in the analysis.

observed

Names of columns in data that are already specified in either within or between that contain predictor variables that are observed variables (i.e. not manipulated).

diff

Names of any variables to collapse to a difference score. If a single value, may be specified by name alone; if multiple values, must be specified as a .() list.

reverse_diff

Logical. If TRUE, triggers reversal of the difference collapse requested by diff. Take care with variables with more than 2 levels.

type

Numeric value (either 1, 2 or 3) specifying the Sums of Squares type to employ when data are unbalanced (eg. when group sizes differ).

white.adjust

Only affects behaviour if the design contains only between-Ss predictor variables. If not FALSE, the value is passed as the white.adjust argument to Anova, which provides heteroscedasticity correction.

detailed

Logical. If TRUE, returns extra information (sums of squares columns, intercept row, etc.) in the ANOVA table.

return_aov

Logical. If TRUE, computes and returns an aov object corresponding to the requested ANOVA (useful for computing post-hoc contrasts).

Value

A list containing one or more components as returned by ez::ezANOVA().

Examples

1
2
3
4
5
6
ez_anova(data = selfesteem2_long,
            dv = score,
            wid = id,
            within = c(time, treatment),
            detailed = TRUE,
            return_aov = TRUE)

psyntur documentation built on Sept. 15, 2021, 5:07 p.m.