Why i am getting this error 'Attempt to execute SCRIPT spline as a function'?
Mostrar comentarios más antiguos
I am using Matlab 2014a latest version. In older versions eg. 2012b the same code is working without error, while in my new version this error appears.
'Attempt to execute SCRIPT spline as a function' In this if i write spline without arguements, still it does not work.
I want to know what is the difference between new and the older versions regarding this. Please help me to correct this error.
Respuestas (2)
Walter Roberson
el 9 de Jun. de 2015
Use
which spline
and show us the result
Anudeep vurity
el 1 de Ag. de 2018
I am facing the same problem
This is the program
x = 0:10; y = sin(x);
xx = 0:.25:10;
pp = spline(x,y,xx);
plot(x,y,'o',xx,yy)
The error I got was 'Attempt to execute SCRIPT spline as a function'
please help!
thank you
3 comentarios
Steven Lord
el 1 de Ag. de 2018
It's likely you have written a script file named spline.m or have downloaded a script file by that name someone else has written. To check this, use the command:
which -all spline
If you see a file listed that is not inside the toolbox directory of your MATLAB installation, that is probably the one shadowing (preventing you from calling) the spline function included in MATLAB. Rename or remove it.
Mbekwa Lemuel Nguh
el 26 de Mayo de 2020
I have rename it in Matlab 2019b but still getting the same error.
Steven Lord
el 26 de Mayo de 2020
Run that command from my comment and show us what it displays.
Categorías
Más información sobre Splines en Centro de ayuda y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!