"Function definitions are not permitted in this context."

1 Ansicht (letzte 30 Tage)
alpedhuez
alpedhuez am 15 Apr. 2018
Beantwortet: David Fletcher am 15 Apr. 2018
I use R2017a and I got the above error message when trying to define a function in a script. Please advise.

Antworten (1)

David Fletcher
David Fletcher am 15 Apr. 2018
If you have a function in a script (allowed from R2016 onwards I think), it must go at the end, after all the script code

Kategorien

Mehr zu Programming finden Sie in Help Center und File Exchange

Produkte

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by