Daniel@0: function varargout = nthoutput(orig,varargin) Daniel@0: Daniel@0: nth.type = 'Integer'; Daniel@0: nth.default = 1; Daniel@0: nth.position = 2; Daniel@0: option.nth = nth; Daniel@0: specif.option = option; Daniel@0: Daniel@0: varargout = mirfunction(@nthoutput,orig,varargin,nargout,specif,@init,@main); Daniel@0: Daniel@0: Daniel@0: function [x type] = init(x,option) Daniel@0: type = mirtype(x); Daniel@0: type = type{option.nth}; Daniel@0: Daniel@0: Daniel@0: function y = main(x,option,postoption) Daniel@0: y = x{option.nth}; Daniel@0: %y = x{1}{option.nth};