How to estimate the optimal number of lags in VAR models from the data?
39 views (last 30 days)
I am fitting a VAR model and I was wondering which commands (if any) in MATLAB calculates the optimal number of lags given the sample data. All the documentation I find online is on how to do it after the fitted model, I would like to get it before, calculated on my data - a similar function in R is called VARselect. Is there anything similar in MATLAB?
azim on 9 Jun 2020
i dont think there is a built in function for that but you can choose using aic and bic criteria. please follow the example on the following link:
hope this helps