Python learning | pandas Remove Columns Notes

There are three ways to select pamdas column:

data [ 'w'] # selected table 'w' column, using dictionary-property returns Series type

selection table data.w # 'w' column, the point of use property returns Series type

data [[ 'w']] # selected table 'w' column, the returned attribute DataFrame

But using the corresponding column can delete del data [ 'w'], and using del data.w del data [[ 'w']] The method will be given.

Guess you like

Origin blog.csdn.net/LivLu24/article/details/94746368