www.gusucode.com > mbcdata 工具箱 matlab 源码程序 > mbcdata/@cgoptim/getOppointPtr.m
function pDS = getOppointPtr(optim, oppoint_name) %GETOPPOINTPTR Get a dataset pointer % % GETOPPOINTPTR(OPTIM, DATASET_NAME) returns a pointer to the named % dataset. % % GETOPPOINTPTR(OPTIM) returns a vector containing all of the dataset % pointers. This vector will contain null pointers for datasets that have % not been chosen yet. % Copyright 2000-2009 The MathWorks, Inc. and Ford Global Technologies, Inc. if nargin>1 ind = getOperatingPointSetIndex(optim.OptimSetup, oppoint_name); if ind==0 error(message('mbc:cgoptim:InvalidLabel3', oppoint_name)); else % return the requested objective pDS = optim.oppoints.Datasets(ind); end else pDS = optim.oppoints.Datasets; end