Can I make a class which behaves like an immutable (float)?
===

I have a class which calculates a moving average which could probably be improved. The size of the averaging window must be flexible.
It currently works by setting the size of the window then sending it updates thus:

    twoday = MovingAverage(2)    # twoday.value is None
    twoday = twoday.update(10)   # twoday.value is None
    twoday = twoday.update(20)   # twoday.value == 15
    twoday = twoday.update(30)   # twoday.value == 25

I thought it would be cool if it worked something more like this:

    twoday = MovingAverage(2)    # twoday is None
    twoday += 10                 # twoday is None
    twoday += 20                 # twoday == 15
    twoday += 30                 # twoday == 25

Is this stupid?
Is it possible?
