<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def variance(self):
 """Variance of the distribution."""

        _self = self._discard_value(None)
        if not _self.total():
            return 0.0
        mean = _self.mean()
        weighted_central_moment = sum(
            count * (value - mean)**2 for value, count in iteritems(_self)
        )
        return weighted_central_moment / float(_self.total())