def _calculate_w(self):
    'Create a diagonal matrix consisting of the difference between our predictions of the 2 Poisson distributions\n        with their observed values\n        '
    (_lambda0, _lambda1) = self._calculate_lambda()
    _w0 = np.diagflat(((self.l0 - _lambda0.reshape((- 1), 1)) ** 2))
    _w1 = np.diagflat(((self.l1 - _lambda1.reshape((- 1), 1)) ** 2))
    return (_w0, _w1)
Create a diagonal matrix consisting of the difference between our predictions of the 2 Poisson distributions
with their observed values
def _calculate_w(self):
    'Create a diagonal matrix consisting of the difference between our predictions of the 2 Poisson distributions\n        with their observed values\n        '
    (_lambda0, _lambda1) = self._calculate_lambda()
    _w0 = np.diagflat(((self.l0 - _lambda0.reshape((- 1), 1)) ** 2))
    _w1 = np.diagflat(((self.l1 - _lambda1.reshape((- 1), 1)) ** 2))
    return (_w0, _w1)