def calcPDSI(model, cid, prec, evap):
    # FIXME: Not functional at the moment
    dt = [date(model.startyear, model.startmonth, model.startday) +
          timedelta(t) for t in range(len(prec))]
    prec = pandas.Series(prec, dt).resample('M', how='mean')
    evap = pandas.Series(evap, dt).resample('M', how='mean')
    # Z = d * K
    pdsi = np.zeros(len(dt))
    # pdsi[1:] = 0.897 * pdsi[:-1] + 1.0 / 3.0 * Z
    return pdsi
Like dict.update() but add counts instead of replacing them.
dataset/ETHPy150Open nasa/RHEAS/src/drought.py/calcPDSI--crossover with--dataset/ETHPy150Open PythonCharmers/python-future/docs/3rd-party-py3k-compat-code/pandas_py3k.py/_Counter.update