Why do I get the error message "Too Many Input/Output Arguments" when I try to execute a function?
Ältere Kommentare anzeigen
Why do I get the following error messages:
Too many output arguments.
Too many input arguments.
Not enough input arguments.
Akzeptierte Antwort
Weitere Antworten (1)
Limabean
am 5 Mai 2017
16 Stimmen
I found an additional way to get the the error "too many input arguments"
I had a class defined in an @folder, with functions in their own files. The primary class definition contains a signature for the function. I had declared 2 arguments in the function, but the signature for the function in the main file still had just one argument.
Solution: make sure the arguments listed in the function signature in your class file matches the arguments in the function you defined in the separate file.
This same thing holds true for "too many output arguments" as well; make sure the function signature matches.
Kategorien
Mehr zu Functions finden Sie in Hilfe-Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!