e3: Get a Contrast Matrix for Type III SS

Description Usage Arguments Details Value Author(s) Examples

View source: R/e3.R

Description

Makes a contrast matrix for type III SS.

Usage

1
  e3(Formula, Data, eps=1e-8)

Arguments

Formula

a conventional formula for a linear model

Data

a data.frame to be analyzed

eps

Less than this value is considered as zero.

Details

It makes a contrast matrix for type III SS.

Value

Returns a contrast matrix for type III SS.

Author(s)

Kyun-Seop Bae k@acr.kr

Examples

1
  round(e3(uptake ~ Plant + Type + Treatment + conc, CO2), 12)

Example output

    (Intercept) PlantMc1 PlantMc2 PlantMc3 PlantMn1 PlantMn2 PlantMn3 PlantQc1
L1            1        0        0        0        0        0        0        0
L2            0        0        0        0        0        0        0        0
L3            0       -1        1        0        0        0        0        0
L4            0       -1        0        1        0        0        0        0
L5            0        0        0        0        0        0        0        0
L6            0        0        0        0       -1        1        0        0
L7            0        0        0        0       -1        0        1        0
L8            0       -1        0        0        1        0        0        1
L9            0       -1        0        0        1        0        0        0
L10           0       -1        0        0        1        0        0        0
L11           0        0        0        0        0        0        0        0
L12           0        0        0        0        0        0        0        0
L13           0        0        0        0        0        0        0        0
L14           0        0        0        0        0        0        0        0
L15           0        0        0        0        0        0        0        0
L16           0        0        0        0        0        0        0        0
L17           0        0        0        0        0        0        0        0
L18           0        0        0        0        0        0        0        0
    PlantQc2 PlantQc3 PlantQn1 PlantQn2 PlantQn3 TypeMississippi TypeQuebec
L1         0        0        0        0        0               0          0
L2         0        0        0        0        0               0          0
L3         0        0        0        0        0               0          0
L4         0        0        0        0        0               0          0
L5         0        0        0        0        0               0          0
L6         0        0        0        0        0               0          0
L7         0        0        0        0        0               0          0
L8         0        0        0        0       -1               0          0
L9         1        0        0        0       -1               0          0
L10        0        1        0        0       -1               0          0
L11        0        0        1        0       -1               0          0
L12        0        0        0        1       -1               0          0
L13        0        0        0        0        0               0          0
L14        0        0        0        0        0               0          0
L15        0        0        0        0        0               0          0
L16        0        0        0        0        0               0          0
L17        0        0        0        0        0               0          0
L18        0        0        0        0        0               0          0
    Treatmentchilled Treatmentnonchilled conc
L1                 0                   0    0
L2                 0                   0    0
L3                 0                   0    0
L4                 0                   0    0
L5                 0                   0    0
L6                 0                   0    0
L7                 0                   0    0
L8                 0                   0    0
L9                 0                   0    0
L10                0                   0    0
L11                0                   0    0
L12                0                   0    0
L13                0                   0    0
L14                0                   0    0
L15                0                   0    0
L16                0                   0    0
L17                0                   0    0
L18                0                   0    1

sasLM documentation built on July 14, 2021, 9:07 a.m.