From d8d2d1e7572cd01cbe2353eb0e45441e222acfb8 Mon Sep 17 00:00:00 2001 From: mmaurostoffel <166130318+mmaurostoffel@users.noreply.github.com> Date: Mon, 13 Jan 2025 17:17:46 +0100 Subject: [PATCH] Werte von 0-1 zu 0-100 angepasst closes #12 --- etl/src/data/etl_region_movAverage.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/etl/src/data/etl_region_movAverage.py b/etl/src/data/etl_region_movAverage.py index 587c034..4549a97 100644 --- a/etl/src/data/etl_region_movAverage.py +++ b/etl/src/data/etl_region_movAverage.py @@ -77,7 +77,7 @@ def region_movingAverage(id: int, scrape_date_start_min: str): values = df.select(pl.exclude("dates")) sum_hor = values.sum_horizontal() - sum_hor = sum_hor / num_properties[arrayCunter] / 2 + sum_hor = sum_hor / num_properties[arrayCunter] / 2 * 100 arrayCunter += 1 newDF = dates.with_columns(sum_hor=pl.Series(sum_hor)) @@ -109,6 +109,5 @@ def region_movingAverage(id: int, scrape_date_start_min: str): # Add moving_averages to df outDF = outDF.with_columns(moving_averages=pl.Series(moving_averages)) - result = {'dates':outDF.get_column('dates').to_list(), 'cap_earlierTimeframe':outDF.get_column('sum_hor_predict').to_list(), 'cap_laterTimeframe':outDF.get_column('sum_hor_actual').to_list(), 'movAvg':outDF.get_column('moving_averages').to_list(),} return result \ No newline at end of file