how can i resolve it not enough input arguments?
1 vue (au cours des 30 derniers jours)
Afficher commentaires plus anciens
function demo(testdir, n, code)
for k = 1:n %getting error in it
0 commentaires
Réponse acceptée
Adam
le 30 Jan 2017
Modifié(e) : Adam
le 31 Jan 2017
Pass the right number of arguments in when you call it. Don't just hit the big green 'Run' button, call it from command line or a script or another function and pass in the arguments.
If you are calling it without arguments how would you expect it to know what n is and didn't you consider that you haven't been able to tell it what n is and that you want to?!
2 commentaires
Adam
le 31 Jan 2017
I have no idea what the function is? But why are you running the function at all if you don't know what it does or what its inputs are supposed to be? I rarely download Matlab code from the internet for exactly this reason of not knowing what its inputs are supposed to be often.
Plus de réponses (0)
Voir également
Catégories
En savoir plus sur Startup and Shutdown dans Help Center et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!