[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Forcing Variable Outputs
From: |
Bill Denney |
Subject: |
Forcing Variable Outputs |
Date: |
Tue, 28 Mar 2006 20:53:39 -0500 (EST) |
I have a function that I want to force to have a variable number of output
arguements based on its calling function's number of output arguements.
In other words, I want to do something like
function [varargout] = fxn1(varargin)
varargout{:} = fxn2(varargin{:});
endfunction
and I want fxn2 to see the same number of output arguements that fxn1
sees.
I thought of initializing varargout like
varargout = cell(1, nargout);
but that didn't work. Is there a way to do this?
Bill
--
From Dumblaws.com: In China, to go to college you must be intelligent.
-------------------------------------------------------------
Octave is freely available under the terms of the GNU GPL.
Octave's home on the web: http://www.octave.org
How to fund new projects: http://www.octave.org/funding.html
Subscription information: http://www.octave.org/archive.html
-------------------------------------------------------------
- Forcing Variable Outputs,
Bill Denney <=