File Exchange

image thumbnail

Multivariate Portmanteau (Ljung-Box) Test

version 1.0.2 (15.3 KB) by Newport Quantitative
Test if there is auto- and cross correlation in a multivariate vector series


Updated 23 Feb 2019

View License

MLBQTEST(X,LAGS) performs multivariate Portmanteau test.

h = mlbqtest(X,LAGS) returns returns a logical value (h) for LAGS with the rejection decision from conducting a multivariate Portmanteau test for joint cross-correlation in a multivariate series X.

h = mlbqtest(X,LAGS,ALPHA) specifies the significance level (default=0.05).

[h,pValue] = mlbqtest(~) returns the rejection decision and p-value for the hypothesis test.

[h,pValue,stat,cValue] = mlbqtest(~) additionally returns the test statistic (stat) and critical value (cValue) for the hypothesis test.

Input argument X: a multivariate time-series (T x k) with k assets and T times.

Test null hypothesis H0: all correlation coefficients are zero, i.e.. rho_1=rho_2=...rho_m=0, where m the lag
Alternative hypothesis H1: there are some coefficients are not zero.

Cite As

Newport Quantitative (2020). Multivariate Portmanteau (Ljung-Box) Test (, MATLAB Central File Exchange. Retrieved .

Comments and Ratings (1)

In Matlab r2017b, the script "mycrosscorr.m" gives an error ("too many input arguments", line 49) since the nested function "crosscorr(X,lags,nlags,nstd) requires the inputs "nlags" and "nstd" as numbers, and does not require the parameter name "crosscov(X,lags,'nlags',nlags,'nstd',nstd) as an input.



Enable customized degree of freedom


Upload needed function for multivariate cross correlation and demo

MATLAB Release Compatibility
Created with R2018b
Compatible with any release
Platform Compatibility
Windows macOS Linux