I am trying to create separate lists for each column in a pandas DF and this code doesn't seem to work and not sure why:
columns = df.columns
for column in columns:
column = list(df[column])
So, if I have a column df['LAT']
, I need a series name LAT with df['LAT']
as values. I am not able to find a way to loop over all the columns to do this but when I select individuals columns it works, like:
LAT = list(df['LAT'])