This example use https://www.mathworks.com/help/econ/var-model-case-study.html as reference.
Loading data from FRED and transforming the data for stationarity
Partitioning the transformed data into presample, estimation, and forecast intervals
Making several models
Fitting the models to the data
Deciding models with various back-testing techniques
Making forecasts based on the best model
Product Focus :
DataFeed Toolbox (Computational Finance Suite)
Econometric Toolbox (Computational Finance Suite)
[Note : Not advocating any particular strategy, factors or methodology]
Kevin Chng (2019). VAR Model To Predict Malaysia/U.S. Foreign Exchange Rate (https://www.mathworks.com/matlabcentral/fileexchange/71767-var-model-to-predict-malaysia-u-s-foreign-exchange-rate), MATLAB Central File Exchange. Retrieved .