I am trying to run a while loop in python and I want to name my dataframes dynamically based on the integration number. Below is the code I have -
while i < count_keys
key_curr = keys[%i]
temp_%i=mod.copy()
temp_%i.groupby([key_curr]).agg({'iclic_id':"count"})
temp_%i.rename(columns={'count':'CT_'key_curr})
I want to know if this way of referencing "%i" is the correct way or is there any other way to reference "i". Thanks for the help!