Skip to content
Snippets Groups Projects
Commit c4cadd36 authored by Peter Lünenschloß's avatar Peter Lünenschloß
Browse files

Update drift.py - fixed bug, resulting from refactoring

parent 3d17ac5e
No related branches found
No related tags found
No related merge requests found
Pipeline #14687 passed with stages
in 10 minutes and 19 seconds
...@@ -389,7 +389,7 @@ def correctExponentialDrift(data: DictOfSeries, field: str, flagger: BaseFlagger ...@@ -389,7 +389,7 @@ def correctExponentialDrift(data: DictOfSeries, field: str, flagger: BaseFlagger
drift_frame.loc[maint_data.values[k] : pd.Timestamp(maint_data.index[k + 1]), "drift_group"] = k drift_frame.loc[maint_data.values[k] : pd.Timestamp(maint_data.index[k + 1]), "drift_group"] = k
drift_grouper = drift_frame.groupby("drift_group") drift_grouper = drift_frame.groupby("drift_group")
# define target values for correction # define target values for correction
shift_targets = shift(-1) shift_targets = drift_grouper.aggregate(lambda x: x[:cal_mean].mean()).shift(-1)
for k, group in drift_grouper: for k, group in drift_grouper:
dataSeries = group[to_correct.name] dataSeries = group[to_correct.name]
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment