File tree Expand file tree Collapse file tree 1 file changed +1
-6
lines changed Expand file tree Collapse file tree 1 file changed +1
-6
lines changed Original file line number Diff line number Diff line change @@ -262,8 +262,6 @@ def extrapolate(
262262 The index does *not* have a ``year`` dimension; the data are implicitly for
263263 `ym1`.
264264 """
265- from sys import version_info
266-
267265 from scipy .optimize import curve_fit
268266
269267 def f (x , b , m ):
@@ -278,11 +276,8 @@ def fitted_intercept(df: pd.DataFrame) -> float:
278276
279277 # Apply fitted_intercept to grouped data
280278 groupby_cols = set (model_data .columns ) - {"year" , "value" }
281- apply_kwargs = {"include_groups" : False } if version_info .minor > 8 else {}
282279 result = (
283- model_data .groupby (list (groupby_cols ))
284- .apply (fitted_intercept , ** apply_kwargs )
285- .rename ("value" )
280+ model_data .groupby (list (groupby_cols )).apply (fitted_intercept ).rename ("value" )
286281 )
287282
288283 # Convert "commodity" and "level" to "sector"
You can’t perform that action at this time.
0 commit comments