undefined function for input arguments of type cell

9 次查看(过去 30 天)
Im trying to produce a regime swithing table using matlab. everything works fine, until the last step. "Undefined function 'MS_Regress_Fit_tvtp' for input arguments of type 'cell'" comes in red, and i cant proceed.
could someone tell me where goes wrong?
here is the code.
--------------------------------------------------
addpath('m_Files_tvtp_20121113'); % add 'm_Files' folder to the search path
addpath('data_Files');
logRet=importdata('tryout.mat'); % load some Data.
dep=logRet(:,1:2:3); % Defining dependent variable from .mat file
constVec=ones(length(dep),1); % Defining a constant vector in mean equation (just an example of how to do it)
indep{1}=constVec; % Defining some explanatory variables
%indep{2}=constVec; % Defining some explanatory variables
% indep{3}=constVec; % Defining some explanatory variables
px=[constVec logRet(:,4)];
px=constVec;
k=2; % Number of States
S{1}=[1 1 1]; % Defining which parts of the equation will switch states (column 1 and variance only)
S{2}=[1 1 1]; % Defining which parts of the equation will switch states (column 1 and variance only)
% S{3}=[1 1]; % Defining which parts of the equation will switch states (column 1 and variance only)
advOpt.distrib='Normal'; % The Distribution assumption ('Normal', 't' or 'GED')
advOpt.distrib='t'; % The Distribution assumption ('Normal', 't' or 'GED')
advOpt.std_method=2; % Defining the method for calculation of standard errors. See pdf file for more details
advOpt.diagCovMat=1;
[Spec_Out]=MS_Regress_Fit_tvtp(dep,indep,px,k,S,advOpt); % Estimating the model

回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Whos 的更多信息

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by