rename data parameter in forecast
This commit is contained in:
parent
b229794e6d
commit
8fa429d477
@ -33,7 +33,7 @@ if TYPE_CHECKING:
|
||||
|
||||
|
||||
def sales_per_customer(
|
||||
df: pd.DataFrame,
|
||||
data: pd.DataFrame,
|
||||
customer_id: int,
|
||||
min_num_data_points: int = 100,
|
||||
) -> FcResult:
|
||||
@ -53,14 +53,13 @@ def sales_per_customer(
|
||||
FcResult
|
||||
_description_
|
||||
"""
|
||||
|
||||
cust_data: CustomerDataSalesForecast = CustomerDataSalesForecast()
|
||||
# filter data
|
||||
# TODO change away from nested DataFrames: just use "f_umsatz_fakt"
|
||||
# TODO with strong type checks
|
||||
df = df.copy()
|
||||
df_firma = df[
|
||||
(df["firma_refid"] == customer_id) & (df["beleg_typ"] == 1) & (df["betrag"] > 0)
|
||||
data = data.copy()
|
||||
df_firma = data[
|
||||
(data["firma_refid"] == customer_id) & (data["beleg_typ"] == 1) & (data["betrag"] > 0)
|
||||
]
|
||||
|
||||
for transaction in df_firma["vorgang_refid"].unique():
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user