Looping over pandas dataframe with track() #2202
-
I'm trying to figure out what the best way is to run a script that loops over a Since for _t in track(list(df.itertuples()), description='processing...'):
print(_t[0]) # print index
... Any other way? |
Beta Was this translation helpful? Give feedback.
Answered by
willmcgugan
Apr 20, 2022
Replies: 1 comment 2 replies
-
You could use |
Beta Was this translation helpful? Give feedback.
2 replies
Answer selected by
astrochun
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
You could use
itertuples
directly, but you would need to supply atotal
argument so Rich knows how many items it contains.