code: def test_VAR_against_statsmodels():
      """Compares Sktime's and Statsmodel's VAR."""
      from statsmodels.tsa.api import VAR as _VAR
  
      train, test = temporal_train_test_split(df)
      sktime_model = VAR()
      fh = ForecastingHorizon([1, 3, 4, 5, 7, 9])
      sktime_model.fit(train)
      y_pred = sktime_model.predict(fh=fh)
  
      stats = _VAR(train)
      stats_fit = stats.fit()
      fh_int = fh.to_relative(train.index[-1])
      lagged = stats_fit.k_ar
      y_pred_stats = stats_fit.forecast(
          train.values[-lagged:], steps=fh_int[-1]
      )
      new_arr = []
      for i in fh_int:
          new_arr.append(y_pred_stats[i - 1])
      assert_allclose(y_pred, new_arr)
  
file_path: sktime/sktime/forecasting/tests/test_var.py
imports: import numpy
  import pandas
  import pytest
  from numpy.testing import assert_allclose
  from sktime.forecasting.base import ForecastingHorizon
  from sktime.forecasting.var import VAR
  from sktime.split import temporal_train_test_split
  from sktime.utils.validation._dependencies import _check_soft_dependencies
label_desc: Use image node_id 1 for calling a global function with example usage: test_VAR_against_statsmodels() without return types