www.gusucode.com > mbcmodels 工具箱 matlab 源码程序 > mbcmodels/@xregrbf/widthstep.m
function [om,OK]= widthstep(m) %XREGRBF/WIDTHSTEP an algorithm to to fit widths and do stepwise % % [om,OK]= widthstep(m); % returns an optimisation manager for i_trialwidths, % Copyright 2000-2014 The MathWorks, Inc. and Ford Global Technologies, Inc. % @xregrbf\widthstep [omWidth,OK] = trialwidths(m); om= contextimplementation(xregoptmgr,m,@i_widthstep,[],'RBF Fit',@widthstep); om = AddOption(om,'WidthAlgorithm',omWidth,'xregoptmgr', 'Width selection algorithm',2); omStep = prune(m); omStep = set(omStep,'Criteria','AICc'); AllOpts= {@minpress,@forwardselect,@backwardselect,@prune,@lsqom}; omStep = setAltMgrs(omStep,AllOpts); om = AddOption(om,'StepAlgorithm',omStep,'xregoptmgr', 'Stepwise',2); function [m,cost,OK,varargout] = i_widthstep(m,om,~,x,y,varargin) omWidth= get(om,'WidthAlgorithm'); %match center selection to the new lambda and width [m,~,OK]=run(omWidth,m,[],x,y); if OK omStep= get(om,'StepAlgorithm'); [m,~,OK]=run(omStep,m,[],x,y); cost= 0; end varargout = cell(1,max(0,nargout-3));