# some example data import numpy as np import pandas import statsmodels.api as sm VAR = sm.tsa.VAR mdata = sm.datasets.macrodata.load_pandas().data # prepare the dates index dates = mdata[['year', 'quarter']].astype(int).astype(str) # the following from the documentation doesn't work for me #quarterly = dates["year"] + "Q" + dates["quarter"] #from statsmodels.tsa.base.datetools import dates_from_str #quarterly = dates_from_str(quarterly) # hacking around, this works q = (mdata[['year']].astype("