Determine A-Matrix.

Share:

Description

Function getAmatrix finds A-matrices used to express ANOVA sum of squares as quadratic forms in y.

Usage

1
getAmatrix(X1, X2)

Arguments

X1

(matrix) lower order model matrix (comprising all factors entering model before 'X2'-factor)

X2

(matrix) higher order model matrix (entering model after 'X1' factors)

Details

Compute A-Matrix for expressing ANOVA Type-1 sequential sum of squares SS as quadratic form in y (column vector of observations), y' * A * y = SS. In random models, when the intercept is the only fixed effect, the design matrix of fixed effects is equal to a column vector where each element is equal to one (1). In this setting, it holds 1' * A * 1 = 0, i.e. all elements of A summing to zero.

This function is not intended to be used directly.

Value

(matrix) for obtaining quadratic forms in y expression ANOVA sum of squares

Author(s)

Andre Schuetzenmeister andre.schuetzenmeister@roche.com

Want to suggest features or report bugs for rdrr.io? Use the GitHub issue tracker.