DOE goodness of fit, residual analysis, comparison, and ANOVA.
The routines in this module operate on a fitted (or user-defined) doe_model and the data used to evaluate it. In each case, the model is evaluated at the M-by-N factor matrix X using doe_evaluate_model, and the result is compared with the M observed responses Y. The factor values must be supplied in the same scale (e.g. coded on [-1, 1]) used when the model was fit.
The number of model parameters, , is taken as the number of
coefficients enabled in the model's usage map (i.e. count(mdl%map)).
Compares two DOE models using the same data set.
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(doe_model), | intent(in) | :: | mdl1 |
The full model. |
||
| class(doe_model), | intent(in) | :: | mdl2 |
The reduced model. |
||
| real(kind=real64), | intent(in), | dimension(:,:) | :: | x |
The M-by-N matrix containing the M values of each of the N factors at which to evaluate both models. |
|
| real(kind=real64), | intent(in), | dimension(:) | :: | y |
The M-element array containing the observed responses. This array must have the same number of rows as x. |
A doe_comparison_result object containing the comparison results.
Computes an analysis of variance (ANOVA) table for a DOE model.
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(doe_model), | intent(in) | :: | mdl |
The DOE model to analyze. |
||
| real(kind=real64), | intent(in), | dimension(:,:) | :: | x |
The M-by-N matrix containing the M values of each of the N factors at which to evaluate the model. |
|
| real(kind=real64), | intent(in), | dimension(:) | :: | y |
The M-element array containing the observed responses. This array must have the same number of rows as x. |
A doe_anova_table object containing the ANOVA table.
Computes model diagnostics and goodness-of-fit metrics.
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(doe_model), | intent(in) | :: | mdl |
The fitted DOE model. |
||
| real(kind=real64), | intent(in), | dimension(:,:) | :: | x |
The M-by-N matrix containing the M values of each of the N factors used in model fitting. |
|
| real(kind=real64), | intent(in), | dimension(:) | :: | y |
The M-element array containing the observed responses. This array must have the same number of rows as x. |
A doe_diagnostics object containing the R-squared, adjusted R-squared, RMSE, residual standard error, F-statistic, mean response, observation count, and parameter count.
Computes residual analysis data for model diagnostics.
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(doe_model), | intent(in) | :: | mdl |
The fitted DOE model. |
||
| real(kind=real64), | intent(in), | dimension(:,:) | :: | x |
The M-by-N matrix containing the M values of each of the N factors at which to evaluate the model. |
|
| real(kind=real64), | intent(in), | dimension(:) | :: | y |
The M-element array containing the observed responses. This array must have the same number of rows as x. |
A doe_residuals object containing the observed values, predicted values, residuals, standardized residuals, and the residual mean and standard deviation.