diff --git a/src/pandas_profiling/model/summary_algorithms.py b/src/pandas_profiling/model/summary_algorithms.py index 5be607cb0..6416e9d16 100644 --- a/src/pandas_profiling/model/summary_algorithms.py +++ b/src/pandas_profiling/model/summary_algorithms.py @@ -51,7 +51,7 @@ def chi_square( values: Optional[np.ndarray] = None, histogram: Optional[np.ndarray] = None ) -> dict: if histogram is None: - bins = bins = np.histogram_bin_edges(values, bins='auto') + bins = bins = np.histogram_bin_edges(values, bins="auto") histogram, _ = np.histogram(values, bins=bins) return dict(chisquare(histogram)._asdict()) diff --git a/tests/issues/test_issue915.py b/tests/issues/test_issue915.py index 15ea33146..6d1703c6b 100644 --- a/tests/issues/test_issue915.py +++ b/tests/issues/test_issue915.py @@ -5,9 +5,12 @@ Error for series with large integers. """ import fnmatch + import pandas as pd + from pandas_profiling import ProfileReport + def test_issue915(): df = pd.DataFrame({"col": pd.Series([716277643516076032 + i for i in range(100)])}) df_profile = ProfileReport(df) @@ -27,4 +30,4 @@ def test_with_value(n_extreme_obs): test_with_value(5) test_with_value(100) - test_with_value(120) \ No newline at end of file + test_with_value(120)