www.gusucode.com > mbctools 工具箱 matlab 源码程序 > mbctools/@sweepsetfilter/private/updateReorderSweeps.m
function [obj, ss] = updateReorderSweeps(obj, ss) %UPDATEREORDERSWEEPS Update the sweep reordering % % [OBJ, SS] = UPDATEREORDERSWEEPS(OBJ, SS) reapplies the sweep reordering % process. If an input sweepset is not provided then one will be % generated. % Copyright 2000-2012 The MathWorks, Inc. and Ford Global Technologies, Inc. % Get the sweepset without sweep reordering f = getFlags; if nargin < 2 ss = ApplyObject(obj, [f.APPLY_DATA f.APPLY_VARS f.APPLY_FILT f.APPLY_TEST f.APPLY_SVAR f.APPLY_SFILT]); end % Store to see if order is changed in the update process INITIAL_order = obj.reorderSweeps; % Make sure that the sweeps reordering is OK if ~isempty(obj.reorderSweeps) % If the number of sweeps is less than or equal to the max in reorder then reset if size(ss, 3) < max(obj.reorderSweeps{1}) obj.reorderSweeps = {}; end % Apply the sweep reorder change ss = ApplyObject(obj, f.APPLY_REOR, ss); end % Has the order actually changed if ~isequaln(obj.reorderSweeps, INITIAL_order) queueEvent(obj, 'ssfSweepOrderChanged'); end % Now cascade the update to the resampling [obj, ss] = updateResampling(obj, ss);