Question: what is lagmatrix in matlab?
Answer: Description. XLAG = lagmatrix(X,Lags) creates a lagged (shifted) version of a time series matrix. The lagmatrix function is useful for creating a regression matrix of explanatory variables for fitting the conditional mean of a return series.