designAnatomy {dae} | R Documentation |

## Given the layout for a design, obtain its anatomy via the canonical analysis of its projectors to show the confounding and aliasing inherent in the design.

### Description

Computes the canonical efficiency factors for the joint
decomposition of two or more structures or sets of mutually orthogonally
projectors (Brien and Bailey, 2009; Brien, 2017; Brien, 2019), orthogonalizing
projectors in a set to those earlier in the set of projectors with
which they are partially aliased. The results can be summarized in the
form of a decomposition table that shows the confounding between sources
from different sets. For examples of the function's use also see the vignette
accessed via `vignette("DesignNotes", package="dae")`

and for a
discussion of its use see Brien, Sermarini and Demetro (2023).

### Usage

```
designAnatomy(formulae, data, keep.order = TRUE, grandMean = FALSE,
orthogonalize = "hybrid", labels = "sources",
marginality = NULL, check.marginality = TRUE,
which.criteria = c("aefficiency","eefficiency","order"),
aliasing.print = FALSE,
omit.projectors = c("pcanon", "combined"), ...)
```

### Arguments

`formulae` |
An object of class |

`data` |
A |

`keep.order` |
A |

`grandMean` |
A |

`orthogonalize` |
A |

`labels` |
A |

`marginality` |
A Each component of the |

`check.marginality` |
A |

`which.criteria` |
A |

`aliasing.print` |
A |

`omit.projectors` |
A |

`...` |
further arguments passed to |

### Details

For each formula supplied in `formulae`

, the set of projectors is
obtained using `pstructure`

; there is one projector
for each term in a formula. Then `projs.2canon`

is used
to perform an analysis of the canonical relationships between two sets
of projectors for the first two formulae. If there are further formulae,
the relationships between its projectors and the already established
decomposition is obtained using `projs.2canon`

. The core
of the analysis is the determination of eigenvalues of the products of
pairs of projectors using the results of James and Wilkinson (1971).
However, if the order of balance between two projection matrices is
10 or more or the James and Wilkinson (1971) methods fails to produce
an idempotent matrix, equation 5.3 of Payne and Tobias (1992) is used
to obtain the projection matrices for their joint decompostion.

The `hybrid`

method is recommended for general use. However, of the
three methods, `eigenmethods`

is least likely to fail, but it
does not establish the marginality between the terms. It is often needed
when there is nonorthogonality between terms, such as when there are
several linear covariates. It can also be more efficeint in these
circumstances.

The process can be computationally expensive, particularly for a large data set (500 or more observations) and/or when many terms are to be orthogonalized.

If the error `Matrix is not idempotent`

should occur then, especially
if there are many terms, one might try using `set.daeTolerance`

to reduce the tolerance used in determining if values are either the same
or are zero; it may be necessary to lower the tolerance to as low as 0.001.
Also, setting `orthogonalize`

to `eigenmethods`

is worth a try.

### Value

### Author(s)

Chris Brien

### References

Brien, C. J. (2017) Multiphase experiments in practice: A look back.
*Australian & New Zealand Journal of Statistics*, **59**, 327-352.

Brien, C. J. (2019) Multiphase experiments with at least one later
laboratory phase . II. Northogonal designs.
*Australian & New Zealand Journal of Statistics*, **61**,
234-268.

Brien, C. J. and R. A. Bailey (2009). Decomposition tables for
multitiered experiments. I. A chain of randomizations.
*The Annals of Statistics*, **36**, 4184-4213.

Brien, C. J., Sermarini, R. A., & Demetrio, C. G. B. (2023). Exposing the
confounding in experimental designs to understand and evaluate them, and
formulating linear mixed models for analyzing the data from a designed
experiment. *Biometrical Journal*, accepted for publication.

James, A. T. and Wilkinson, G. N. (1971) Factorization of the residual
operator and canonical decomposition of nonorthogonal factors in the
analysis of variance. *Biometrika*, **58**, 279-294.

Payne, R. W. and R. D. Tobias (1992). General balance, combination of
information and the analysis of covariance.
*Scandinavian Journal of Statistics*, **19**, 3-23.

### See Also

`designRandomize`

, `designLatinSqrSys`

, `designPlot`

,

`pcanon.object`

, `p2canon.object`

,
`summary.pcanon`

, `efficiencies.pcanon`

,
`pstructure`

,

`projs.2canon`

, `proj2.efficiency`

, `proj2.combine`

,
`proj2.eigen`

, `efficiency.criteria`

,
in package dae,

`eigen`

.

`projector`

for further information about this class.

### Examples

```
## PBIBD(2) from p. 379 of Cochran and Cox (1957) Experimental Designs.
## 2nd edn Wiley, New York
PBIBD2.unit <- list(Block = 6, Unit = 4)
PBIBD2.nest <- list(Unit = "Block")
trt <- factor(c(1,4,2,5, 2,5,3,6, 3,6,1,4, 4,1,5,2, 5,2,6,3, 6,3,4,1))
PBIBD2.lay <- designRandomize(allocated = trt,
recipient = PBIBD2.unit,
nested.recipients = PBIBD2.nest)
##obtain combined decomposition and summarize
unit.trt.canon <- designAnatomy(formulae = list(unit=~ Block/Unit, trt=~ trt),
data = PBIBD2.lay)
summary(unit.trt.canon, which.criteria = c("aeff","eeff","order"))
summary(unit.trt.canon, which.criteria = c("aeff","eeff","order"), labels.swap = TRUE)
## Three-phase sensory example from Brien and Payne (1999)
## Not run:
data(Sensory3Phase.dat)
Eval.Field.Treat.canon <- designAnatomy(formulae = list(
eval= ~ ((Occasions/Intervals/Sittings)*Judges)/Positions,
field= ~ (Rows*(Squares/Columns))/Halfplots,
treats= ~ Trellis*Method),
data = Sensory3Phase.dat)
summary(Eval.Field.Treat.canon, which.criteria =c("aefficiency", "order"))
## End(Not run)
```

*dae*version 3.2.28 Index]