I have error codes when which I am unsure how to fix
31 visualizaciones (últimos 30 días)
Mostrar comentarios más antiguos
This is the what the command window is saying after I try to run my code:
fminunc requires Optimization Toolbox.
Error in runMe (line 65)
fminunc(@(t)(costFunctionReg(t, X, y, lambda)), initial_theta, options);
Error in run (line 99)
evalin('caller', strcat(script, ';'));
2 comentarios
Dyuman Joshi
el 19 de Dic. de 2023
[status,errmsg] = license('checkout','Optimization_Toolbox')
Run this code and see if you have the Optimization Toolbox licensed or not.
If status is 1, you have it licensed and download and install the toolbox from the Add-ons.
If status is 0, you will need to purchase the toolbox.
Respuestas (1)
arushi
el 2 de Sept. de 2024
Hi Danny,
It seems that you are encountering the above error code because of the absence of the 'Optimization ToolBox'. You can verify if you have the license for the same or not by using the following command:
a = license('test','Optimization_Toolbox')
% a = 1 denotes that you have the license of the toolbox therefore you have to
% install it from the Add-ons.
% a = 0 denotes the absence of license of the toolbox therefore you have to purchase it
% for the Optimization_Toolbox
You can also verify if the toolbox is installed or not by using the following command:
v = ver;
a = any(strcmp('Optimization Toolbox', {v.Name}))
% a = 1 denotes that the toolbox is installed but since it is showing the error therefore
% you should try reinstalling it from the Add-ons.
% a = 0 denotes that the toolbox is not installed therefore you should
% install it from the Add-ons.
I hope it helps!
0 comentarios
Ver también
Categorías
Más información sobre Introduction to Installation and Licensing en Help Center y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!