www.gusucode.com > econ 案例源码程序 matlab代码 > econ/ConducttheDefaultIntegrationandStationarityTestsExample.m

    %% Conduct the Default Integration and Stationarity Tests  
% Conduct paired integration and stationarity tests on two time series using
% the default tests and settings.   

% Copyright 2015 The MathWorks, Inc.


%% 
% Load the Nelson-Plosser data, and extract the series of real GNP, |GNPR|,
% and consumer price index, |CPI|. 
load Data_NelsonPlosser		
X = DataTable{:,{'GNPR','CPI'}};  
%%
% |X| is a matrix containing the data for the variables |GNPR| and |CPI|.
%% 
% Conduct the default integration (|adftest|) stationarity (|kpsstest|)
% tests on the two time series. 
i10test(X) 

%%
% The warnings indicate that the p-values are very large for |adftest| and
% very small for |kpsstest| (that is, they are outside the Monte Carlo simulated
% tables). For both series, a unit root is not rejected (|H = 0| for |I(1)|),
% and stationarity is rejected (|H = 1| for |I(0)|).