www.gusucode.com > mbcdata 工具箱 matlab 源码程序 > mbcdata/@cgoppoint/findname.m
function index = findname(d,name) % cgOpPoint / findname % Copyright 2000-2011 The MathWorks, Inc. and Ford Global Technologies, Inc. index = []; if isa(name,'pointer') for i = 1:length(name) this = find(name(i) == d.ptrlist); if isempty(this) index = []; return else index = [index;this]; end end else names = get(d,'factors'); if ~isempty(names) names = strrep(names,'(',''); names = strrep(names,')',''); if ischar(name) name = {name}; end for i = 1:length(name) this = find( strcmpi( name{ i },names ) ); if isempty(this) index = []; return end index = [index;this]; end end end