I have created a regression model using Statistics and Machine Learning Toolbox that is dependent on 6 variables. After exporting the model to the workspace, I now want to determine the global minimum of the function using "surrogateopt".
With my code, the solver varies the attributes in the specified interval, but the result of the output "fval" does not change.
Can anyone help me with this problem?
objconstr = @(x)trainedModel.predictFcn(data);
lb = [-10,-10,-10,-10,-10,-10];
ub = [10,10,10,10,10,10];
[x,fval] = surrogateopt(objconstr,lb,ub);
trainedModel.predictFcn is the name of the function
data is a table with the 6 attributes