MATLAB: Cointegration examples fail (e.g. canadian interest rates) with error: Undefined function ‘jcitest’ for input arguments of type ‘double’

cointegrationEconometrics Toolboxegcitest

I cannot run the example for the 'egcitest': all works about this part:
load Data_Canada
Y = Data(:,3:end);
figure
plot(dates,Y,'LineWidth',2)
xlabel 'Year';
ylabel 'Percent';
names = series(3:end);
legend(names,'location','NW')
title '{\bf Canadian Interest Rates, 1954-1994}';
axis tight
grid on
but then when I run
[h,pValue,stat,cValue] = egcitest(Y,'test',{'t1','t2'})
I get the message:
Undefined function 'egcitest' for input arguments of type 'cell'.
If I just try:
[h,pValue,stat,cValue] = egcitest(Y)
I get the message: Undefined function 'egcitest' for input arguments of type 'double'.
Running 'ver' I get this:
ver
—————————————————————————————————-
MATLAB Version: 8.6.0.267246 (R2015b)
MATLAB License Number: 526221
Operating System: Microsoft Windows 7 Enterprise Version 6.1 (Build 7601: Service Pack 1)
Java Version: Java 1.7.0_60-b19 with Oracle Corporation Java HotSpotâ„¢ 64-Bit Server VM mixed mode
—————————————————————————————————-
MATLAB Version 8.6 (R2015b)
Database Toolbox Version 6.0 (R2015b)
Datafeed Toolbox Version 5.2 (R2015b)
Econometrics Toolbox Version 3.3 (R2015b)
Financial Instruments Toolbox Version 2.2 (R2015b)
Financial Toolbox Version 5.6 (R2015b)
MATLAB Compiler Version 6.1 (R2015b)
MATLAB Compiler SDK Version 6.1 (R2015b)
Mapping Toolbox Version 4.2 (R2015b)
Optimization Toolbox Version 7.3 (R2015b)
Parallel Computing Toolbox Version 6.7 (R2015b)
Spreadsheet Link EX Version 3.2.4 (R2015b)
Statistics and Machine Learning Toolbox Version 10.1 (R2015b)
Can someone please help?

Best Answer

You could get that output from ver() if you have the Econometrics toolbox installed but you do not have a license for it. Try
which -all egcitest
and see what it says. If it says "No license available" then that would be pretty clear.
Related Question