lijst = []
lst_credit_not_found = []
for i in range( int(df_credit['SRLNO'].max() +1)):
df_credit_group = df_credit[df_credit['SRLNO']==i]
df_debet_tmp=df_debet[~df_debet.ID_FACTUURREGEL.isin(lijst)]
for index, row in df_credit_group.iterrows():
rows,columns =df_debet_tmp[df_debet_tmp["C_FACTUUR"]==row["C_FACTUUR"]].shape
if rows<1:
lst_credit_not_found.append(df_debet_tmp[df_debet_tmp["C_FACTUUR"]==row["C_FACTUUR"]].iloc[0]["ID_FACTUURREGEL"])
else:
lijst.append(df_debet_tmp[df_debet_tmp["C_FACTUUR"]==row["C_FACTUUR"]].iloc[0]["ID_FACTUURREGEL"])
'werkend
lijst = []
for i in range( int(df_credit['SRLNO'].max() +1)):
df_credit_group = df_credit[df_credit['SRLNO']==i]
df_debet_tmp=df_debet[~df_debet.ID_FACTUURREGEL.isin(lijst)]
for index, row in df_credit_group.iterrows():
lijst.append(df_debet_tmp[df_debet_tmp["C_FACTUUR"]==row["C_FACTUUR"]].iloc[0]["ID_FACTUURREGEL"])
woensdag 4 juli 2018
Abonneren op:
Reacties posten (Atom)
Datums bepalen adhv begin en einddatum in Dataframe
Voorbeeld op losse velden ####################################################################### # import necessary packages from datetime...
-
handig https://www.shanelynn.ie/summarising-aggregation-and-grouping-data-in-python-pandas/ import pandas factuurlines = pd.read_csv(...
-
Importeer CSV naar Dataframe import pandas factuurlines = pd.read_csv("df_debet_geschoond.csv",sep=";",engine='pyt...
-
The Pandas loc indexer can be used with DataFrames for two different use cases: a.) Selecting rows by label/index b.) Selecting r...
Geen opmerkingen:
Een reactie posten