Attempt to execute SCRIPT <filename> as a function
Mostra commenti meno recenti
Hi all, I am a new user of Matlab. Im learning how to debug a .m file called "test.m". I was asked to copy one backup, I made the name "test_debug.m". When I run the test_debug.m file, there is a error msg,
Attempt to execute SCRIPT test as a function: D:\ProgramFiles\Reference_src\test.m
test.m is not in path. But it could still successful run. It has called several functions inside the script. What should I add into/make changes for test_debug.m?
Thank you!
3 Commenti
zakria qadir
il 13 Ago 2020
i am getting this error?
Attempt to execute SCRIPT newplot as a function:
D:\MATLAB\R2017a\toolbox\matlab\graphics\newplot.m
Error in contour (line 66)
cax = newplot(cax);
Error in PSO_simulation (line 19)
contour(x_new, y_new, z , 20);
>>
Image Analyst
il 14 Ago 2020
Chances are you named your m-file after a built-in function. Attach your m-file with the paper clip icon in a new question.
Walter Roberson
il 14 Ago 2020
You would get that error message if you had accidentally corrupted newplot.m such as accidentally typing in a few characters before the 'function' line.
Risposta accettata
Più risposte (0)
Categorie
Scopri di più su Entering Commands in Centro assistenza e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!