annotate toolboxes/MIRtoolbox1.3.2/MIRToolbox/nthoutput.m @ 0:e9a9cd732c1e tip

first hg version after svn
author wolffd
date Tue, 10 Feb 2015 15:05:51 +0000
parents
children
rev   line source
wolffd@0 1 function varargout = nthoutput(orig,varargin)
wolffd@0 2
wolffd@0 3 nth.type = 'Integer';
wolffd@0 4 nth.default = 1;
wolffd@0 5 nth.position = 2;
wolffd@0 6 option.nth = nth;
wolffd@0 7 specif.option = option;
wolffd@0 8
wolffd@0 9 varargout = mirfunction(@nthoutput,orig,varargin,nargout,specif,@init,@main);
wolffd@0 10
wolffd@0 11
wolffd@0 12 function [x type] = init(x,option)
wolffd@0 13 type = mirtype(x);
wolffd@0 14 type = type{option.nth};
wolffd@0 15
wolffd@0 16
wolffd@0 17 function y = main(x,option,postoption)
wolffd@0 18 y = x{option.nth};
wolffd@0 19 %y = x{1}{option.nth};