File tree Expand file tree Collapse file tree 1 file changed +6
-1
lines changed Expand file tree Collapse file tree 1 file changed +6
-1
lines changed Original file line number Diff line number Diff line change 12
12
import re
13
13
import six
14
14
15
+ try :
16
+ _pandas_is_subperiod = pd .tseries .frequencies .is_subperiod
17
+ except AttributeError :
18
+ _pandas_is_subperiod = pandas ._libs .tslibs .frequencies .is_subperiod
19
+
15
20
# # imports for timing the performance;
16
21
# # there are also commented lines in the code referring to timeit or timers
17
22
# import timeit
@@ -128,7 +133,7 @@ def _check_groupby_freq(base_unit_freq, group_by_freq):
128
133
True if `group_by_freq` can be used for grouping, False otherwise.
129
134
"""
130
135
if bool (
131
- pd . tseries . frequencies . is_subperiod (base_unit_freq , group_by_freq )
136
+ _pandas_is_subperiod (base_unit_freq , group_by_freq )
132
137
# Some combinations of arguments result in is_subperiod function
133
138
# returning nothing (NoneType)
134
139
):
You can’t perform that action at this time.
0 commit comments