def is_normal(r, level=0.01):
    '\n    Applies the Jarque-Bera test to determine if a Series is normal or not\n    Test is applied at the 1% level by default\n    Returns True if the hypothesis of normality is accepted, False otherwise\n    '
    if isinstance(r, pd.DataFrame):
        return r.aggregate(is_normal)
    else:
        (statistic, p_value) = scipy.stats.jarque_bera(r)
        return (p_value > level)
Applies the Jarque-Bera test to determine if a Series is normal or not
Test is applied at the 1% level by default
Returns True if the hypothesis of normality is accepted, False otherwise
def is_normal(r, level=0.01):
    '\n    Applies the Jarque-Bera test to determine if a Series is normal or not\n    Test is applied at the 1% level by default\n    Returns True if the hypothesis of normality is accepted, False otherwise\n    '
    if isinstance(r, pd.DataFrame):
        return r.aggregate(is_normal)
    else:
        (statistic, p_value) = scipy.stats.jarque_bera(r)
        return (p_value > level)