def _safe_divide(self, numerator, denominator):
    '\n        Division routine that avoids division-by-zero errors\n        (returning zero in such cases) but keeps track of them\n        for undefined_values().\n        '
    if (denominator == 0):
        self.undefined_vals += 1
        return 0
    else:
        return (numerator / denominator)
Division routine that avoids division-by-zero errors
(returning zero in such cases) but keeps track of them
for undefined_values().
def _safe_divide(self, numerator, denominator):
    '\n        Division routine that avoids division-by-zero errors\n        (returning zero in such cases) but keeps track of them\n        for undefined_values().\n        '
    if (denominator == 0):
        self.undefined_vals += 1
        return 0
    else:
        return (numerator / denominator)