Breaks a model term down into its basic contrasts (R.W. Payne).

### Options

`TERM` = formula |
Model term to split into basic contrasts |
---|---|

`PSEUDOFACTORS` = pointer |
Pseudo-factors representing the basic contrasts |

`NEWTERMS` = formula structure |
Model formula containing the term followed by the pseudofactors |

### No parameters

### Description

It is well known that the interaction between factors `F1`

, `F2`

… `Fm`

(each with prime *p* numbers of levels) can be partitioned into (*p*-1)**(*m*-1) orthogonal sets of contrasts, known as basic contrasts (e.g. Kempthorne 1952, page 321). They are usually written as

`F1**`

*k*_{1} `F2**`

*k*_{2} … `Fn**`

*k _{n}*

where conventionally

=1 and 1≤*k*_{1}

<*k _{i}*

*p*. Each set of basic contrasts represents comparisons between

*p*sets of factor combinations, the ith of which contains the factor combinations

*f*

_{1}…

*f*such that

_{m}*k*_{1} × *f*_{1} + *k*_{2} × *f*_{2} + … *k _{m}* ×

*f*=

_{m}*i*mod(

*p*)

In most straightforward experimental designs, all the contrasts of each treatment interaction are estimated in a single stratum. When this is not feasible, a popular strategy is form the design so that different sets of basic contrasts are estimated in different strata. This underlies the design key method, which is used by the `GENERATE`

directive and the `AKEY`

procedure.

When a design key has been used to generate the design, the `FPSEUDOFACTORS`

directive may be used to form the pseudo-factors required to cope with interactions (or other model terms) whose contrasts are estimated in different strata. If this pseudo-factoring is not included, the `ANOVA`

directive will warn that the design contains partial confounding.

When no design key is available, provided all the treatment terms are main effects or interactions all of whose factors have the same prime number of levels, an alternative strategy is to use the `FBASICCONTRASTS`

procedure to break up each partially-confounded interaction into its sets of basic contrasts. The interaction is specified using the `TERM`

option. The `PSEUDOFACTORS`

option saves a pointer containing the factors generated to represent the basic contrasts. Finally, the `NEWTERMS`

option can save a new model formula containing the interaction followed by the pseudo-factor operator `//`

and then the list of pseudo-factors. For example, for the interaction of two 3-level factors `A`

and `B`

, the `NEWTERMS`

formula would be

`A.B // (Pf[1,2])`

where `Pf[]`

is the pointer of pseudo-factors.

Options: `TERM`

, `PSEUDOFACTORS`

, `NEWTERMS`

.

Parameters: none.

### Method

`FBASICCONTRASTS`

uses the `PRIMEPOWER`

procedure to check that all factors have a prime number of levels. It then constructs a design key with a row for every set of basic contrasts, and forms the pseudo-factors using `GENERATE`

.

### See also

Procedures: `AFUNITS`

, `FACCOMBINATIONS`

, `FACDIVIDE`

, `FACPRODUCT`

.

Commands for: Calculations and manipulation, Design of experiments.

### Example

CAPTION 'FBASICCONTRASTS example',\ !t('3**3 design with part of the 3-factor interaction',\ 'confounded with blocks.'); STYLE=meta,plain FACTOR [NVALUES=81; LEVELS=3] Blocks,N,P,K READ Blocks 1 1 1 2 2 2 3 3 3 2 2 2 3 3 3 1 1 1 3 3 3 1 1 1 2 2 2 2 2 2 3 3 3 1 1 1 3 3 3 1 1 1 2 2 2 1 1 1 2 2 2 3 3 3 3 3 3 1 1 1 2 2 2 1 1 1 2 2 2 3 3 3 2 2 2 3 3 3 1 1 1 : GENERATE N,P,K,3 BLOCKSTRUCTURE Blocks TREATMENTS N*P*K ANOVA " N.P.K is partially confounded with Blocks: split this up into its basic contrasts, and include these in the model formula." FBASICCONTRASTS [TERM=N.P.K; PSEUDOFACTORS=Pf; NEWTERMS=Pseudoterms] PRINT Pseudoterms PRINT [RLWIDTH=8; WIDTH=62; ORIENTATION=across] N,P,K,Pf[]; FIELD=2 " The basic contrasts account for all of N.P.K, so N.P.K itself will be aliased." TREATMENTS N*P*K - N.P.K + #Pseudoterms ANOVA