SumToZero {bfw} | R Documentation |
Sum to Zero
Description
Compute sum to zero values across all levels of a data matrix
Usage
SumToZero(q.levels, data, contrasts)
Arguments
q.levels |
number of levels of each variable/column |
data |
data matrix to combine from |
contrasts |
specified contrasts columns |
Examples
data <- matrix(c(1,2),ncol=2)
colnames(data) <- c("m1[1]","m1[2]")
SumToZero( 2 , data , contrasts = NULL )
# b0[1] b1[1] b1[2]
# m1[1] 1.5 -0.5 0.5
[Package bfw version 0.4.2 Index]