[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: varargout{:} = func() ?
From: |
John W. Eaton |
Subject: |
Re: varargout{:} = func() ? |
Date: |
Wed, 24 Feb 2010 01:27:01 -0500 |
On 24-Feb-2010, forkandwait wrote:
| > I don't have Matlab to try at hand. What do you think these should do?
|
| Link to a matlab example which currently doesn't work on octave (the part
about
| output parameters doesn't, the part about input params works fine):
|
| http://www.mathworks.com/matlabcentral/newsreader/view_original/720201
Maybe that example is wrong?
I think you will find that Matlab also needs to know the number of
outputs before it can call the function. So as we said before,
v = cell (expected_outputs, 1);
[v{:}] = func (...);
should work in any recent version of Octave. If it does not, then
please submit a complete bug report to the address@hidden mailing
list. But first, please read http://www.octave.org/bugs.html to see
what information you should include in your report so that it is
helpful.
OTOH,
clear v;
[v{:}] = func (...);
will not work, because Octave can't determine nargout for the function
call. I expect this is also true in Matlab.
jwe
Re: varargout{:} = func() ?, Jaroslav Hajek, 2010/02/23
Re: varargout{:} = func() ?, Jaroslav Hajek, 2010/02/24
Re: varargout{:} = func() ?, Ben Abbott, 2010/02/24
Re: varargout{:} = func() ?, Ben Abbott, 2010/02/24