Calculate summary statistics of columns in dataframe

后端 未结 3 1805
萌比男神i
萌比男神i 2020-12-07 20:38

I have a dataframe of the following form (for example)

shopper_num,is_martian,number_of_items,count_pineapples,birth_country,tranpsortation_method
1,FALSE,0,         


        
3条回答
  •  鱼传尺愫
    2020-12-07 21:03

    To clarify one point in @EdChum's answer, per the documentation, you can include the object columns by using df.describe(include='all'). It won't provide many statistics, but will provide a few pieces of info, including count, number of unique values, top value. This may be a new feature, I don't know as I am a relatively new user.

提交回复
热议问题