cpa(formula, data, k = 100, na.action = "na.fail", family = "gaussian",
weights = NULL)formula of the form response ~ terms.family.critpat is returned, listing the following components:
lvl.comp- the level componentpat.comp- the pattern componentb- the unstandardized regression weightsbstar- the mean centered regression weightsxc- the scalar constant times bstark- the scale constantCovpc- the pattern effectYpred- the predicted valuesr2- the proportion of variability attributed to the different componentsF.table- the associated F-statistic tableF.statistic- the F-statisticsdf- the df used in the testpvalue- the p-values for the testcpa function requires two arguments: criterion and predictors. The function returns the criterion-related profile analysis described in Davison & Davenport (2002). Missing data are presently handled by specifying na.action = "na.omit", which performs listwise deletion and na.action = "na.fail", the default, which causes the function to fail. The following S3 generic functions are available: summary(),anova(), print(), and plot(). These functions provide a summary of the analysis (namely, R2 and the level and pattern components); perform ANOVA of the R2 for the pattern, the level, and the overall model; provide output similar to lm(), and plots the pattern effect.pcvdata(IPMMc)
mod <- cpa(R ~ A + H + S + B, data = IPMMc)
print(mod)
summary(mod)
plot(mod)
anova(mod)Run the code above in your browser using DataLab