Tech Support has classified it as "a bug in MATLAB Live Editor for 'nargout' function".
nargout unavailable in anonymous functions when run from Live Script
1 view (last 30 days)
Show older comments
The following code works fine at the command line and in mfile scripts.
>>f=@()nargout
>> f()
ans =
0
>> a=f()
a =
1
However, it fails when run as a Live Script:
f=@()nargout;
f()
a=f()
I am curious as to why.
0 Comments
Accepted Answer
More Answers (0)
See Also
Categories
Find more on Argument Definitions in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!