Learn R Programming

micompr (version 1.1.4)

assumptions_paruv: Determine the assumptions for the parametric comparison test

Description

Determine two assumptions for the parametric comparison tests (i.e. either t.test or aov) for each principal component, namely: a) univariate normality of each group; b) homogeneity of variances.

Usage

assumptions_paruv(data, factors)

Value

An object of class assumptions_paruv which is a list containing two elements:

uvntest

List of results from the Shapiro-Wilk normality test (shapiro.test), one result per group per principal component.

vartest

Result of Bartlett test for homogeneity of variances (bartlett.test).

Arguments

data

Data used in the parametric test (rows correspond to observations, columns to principal components).

factors

Groups to which rows of data belong to.

Examples

Run this code

# Determine the assumptions of applying ANOVA to each column (dependent
# variable) of the iris data (i.e. normality of each group and homogeneity of
# variances)
a <- assumptions_paruv(iris[, 1:4], iris[, 5])

Run the code above in your browser using DataLab