How to add a categorical variable with a power of 2 to the rowexch function (D-opt design)
1 view (last 30 days)
Show older comments
Hello,
Given: A regression model with polynomial function 'poly42111'. The second factor has a power of 2 and is/can modeled as a continuous variable. However, the complete data set only has 4 levels of this factor.
Problem: To reduce the amount of data points required the model is subjected to a D-optimal design, by means of the rowexch function. To ensure the D-optimal design matrix contains available data only -- thus a selection of the four levels for the second factor -- the function is defined as follows:
dRE1 = rowexch(nfactors,points,'poly42111','categorical',2,'levels',4);
but now the following error occurs:
MODEL cannot specify powers for a categorical variable.
The rowexch function does not support categorical variables with power > 1. In fact, a simple regression model neither supports a factor with power >1 to be defined as categorical...
Question: Does anyone have a solution to this? different method / post-augmentation of this factor..
Help is much appreciated, thanks in advance!
Floris
0 Comments
Answers (0)
See Also
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!