changed max.lag to lag.max to match with R standard time series functions.