I have a dictionary d
full of a collection of dataframes:
key type size value
gm1 dataframe mxn ....
gm2 dataframe mxN ...
..
gm10 dataframe nxM ...
I want to output these dataframes one-by-one using their keys
as the names of the new dataframes. I try doing this first by iterating over the keys of the dictionary:
for key in d.keys():
key = d[key]
This gives me the output of the last dataframe gm10
and obviously names it key
because it simply updates the name as key rather than naming the output dataframes as their keys.
Is there an easy way to get gm1
, gm2
,....gm10
each as their own named dataframes?