offset#

offset(i)[source]#

Time interval in step i

This cells if for controlling the number of months in step i. Step i is from one day after date_(i) to date_(i+1). This cells should return an object of a sub calass of pandas DateOffset, such as MonthEnd and YearEnd object. The returned object must always represent end of month, and must not be longer than 1 year.

To set the length of step i to N monthhs, offset(i) should return pd.offsets.MonthEnd(N). To set the length to 1 year, offset(i) should return pd.offsets.Year(1).

By default, the formula is set so that the model projects monthly for the first 60 months (5 years) then annually after that.

offset() is defined as:

if i < 60:
    return pd.offsets.MonthEnd(1)
else:
    return pd.offsets.YearEnd(1)

See also