MATLAB: Second output argument as input argument argumentsinputMATLABoutput Is it possible to combine the two lines: [~,b] = myfunction(x); c = myfunction2(b); Something like: c = myfunction2(myfunction(x){2}) ?? Best Answer There is no MATLAB syntax or built-in function that supports what you want to do, unfortunately. Related SolutionsMATLAB: Only accept odd numbered input arguments nargin counts the number of input arguments for a function. mod(x,2) returns 1 when x is odd.if mod(nargin,2)~=1 error('There must be an odd number of inputs.')end MATLAB: Argument Question I think this is what they meant -In the function file:function outputVar = myfunction(inputVar)% write the rest of the program here, using inputVar as you would a stringWhen you call the function you give it a string:thisoutput = myfunction('data1.txt') Related QuestionArgument passing issue.How to check if output argument is ignoredWhat does the tilde (~) in the following code meanAbout function argument
Best Answer