How to show all of columns name on pandas dataframe?

后端 未结 13 2176
既然无缘
既然无缘 2020-12-07 08:24

I have a dataframe that consist of hundreds of columns, and I need to see all column names.

What I did:

In[37]:
data_all2.columns

T

13条回答
  •  甜味超标
    2020-12-07 08:56

    In the interactive console, it's easy to do:

    data_all2.columns.tolist()
    

    Or this within a script:

    print(data_all2.columns.tolist())
    

提交回复
热议问题