How to have a function have any number of input arguments
2 views (last 30 days)
I am trying to make my own function in matlab. I want to make it so it'll run with whatever amount of input arguments. So this is what I have right now essentially:
And my function works for one input argument. But I want to have the option of running multiple input arguments. I want to do this without having to retype the function command over and over again. So basically I want to do:
myfunction(data1,data2,data3) . . . . etc
Can this be done?