a slightly shorter version of the answer:

Copydf.describe(include = 'object')
Answer from IndPythCoder on Stack Overflow
๐ŸŒ
Pandas
pandas.pydata.org โ€บ docs โ€บ user_guide โ€บ categorical.html
Categorical data โ€” pandas 3.0.2 documentation - PyData |
Categoricals are a pandas data type corresponding to categorical variables in statistics. A categorical variable takes on a limited, and usually fixed, number of possible values (categories; levels in R).
๐ŸŒ
Pandas
pandas.pydata.org โ€บ pandas-docs โ€บ stable โ€บ user_guide โ€บ categorical.html
Categorical data โ€” pandas 3.0.1 documentation - PyData |
Categoricals are a pandas data type corresponding to categorical variables in statistics. A categorical variable takes on a limited, and usually fixed, number of possible values (categories; levels in R).
๐ŸŒ
Statology
statology.org โ€บ home โ€บ pandas: how to use describe() for categorical variables
Pandas: How to Use describe() for Categorical Variables
March 8, 2023 - #calculate categorical descriptive statistics for all variables df.astype('object').describe() team points assists rebounds count 8 8 8 8 unique 8 7 5 7 top A 14 9 6 freq 1 2 3 2 ยท The output shows count, unique, top and freq for every variable in the DataFrame, including the numeric variables. The following tutorials explain how to perform other common operations in pandas:
๐ŸŒ
Pandas
pandas.pydata.org โ€บ pandas-docs โ€บ version โ€บ 0.23.4 โ€บ categorical.html
Categorical Data โ€” pandas 0.23.4 documentation
Categoricals are a pandas data type corresponding to categorical variables in statistics. A categorical variable takes on a limited, and usually fixed, number of possible values (categories; levels in R).
๐ŸŒ
Pandas
pandas.pydata.org โ€บ docs โ€บ reference โ€บ api โ€บ pandas.DataFrame.describe.html
pandas.DataFrame.describe โ€” pandas 3.0.1 documentation
>>> df.describe(include="all") categorical numeric object count 3 3.0 3 unique 3 NaN 3 top f NaN a freq 1 NaN 1 mean NaN 2.0 NaN std NaN 1.0 NaN min NaN 1.0 NaN 25% NaN 1.5 NaN 50% NaN 2.0 NaN 75% NaN 2.5 NaN max NaN 3.0 NaN
๐ŸŒ
Pandas
pandas.pydata.org โ€บ pandas-docs โ€บ version โ€บ 0.25.3 โ€บ user_guide โ€บ categorical.html
Categorical data โ€” pandas 0.25.3 documentation
Categoricals are a pandas data type corresponding to categorical variables in statistics. A categorical variable takes on a limited, and usually fixed, number of possible values (categories; levels in R).
๐ŸŒ
TutorialsPoint
tutorialspoint.com โ€บ python_pandas โ€บ python_pandas_categorical_data.htm
Python Pandas - Categorical Data
Using the .describe() command on the categorical data, we get similar output to a Series or DataFrame of the type string. The following example demonstrates how to get the description of Pandas categorical DataFrame using the describe() method.
Find elsewhere
๐ŸŒ
Pandas
pandas.pydata.org โ€บ pandas-docs โ€บ version โ€บ 0.18.0 โ€บ categorical.html
Categorical Data โ€” pandas 0.18.0 documentation
Categoricals are a pandas data type, which correspond to categorical variables in statistics: a variable, which can take on only a limited, and usually fixed, number of possible values (categories; levels in R).
๐ŸŒ
GeeksforGeeks
geeksforgeeks.org โ€บ pandas โ€บ python-pandas-dataframe-describe-method
Pandas DataFrame describe() Method - GeeksforGeeks
July 26, 2025 - The describe() method in Pandas ... with numeric data by default but can also handle categorical data which offers insights like the most frequent value and the number of unique entries....
๐ŸŒ
Pandas
pandas.pydata.org โ€บ docs โ€บ reference โ€บ api โ€บ pandas.Categorical.html
pandas.Categorical โ€” pandas 3.0.1 documentation - PyData |
class pandas.Categorical(values, categories=None, ordered=None, dtype=None, copy=True)[source]# Represent a categorical variable in classic R / S-plus fashion. Categoricals can only take on a limited, and usually fixed, number of possible values (categories).
๐ŸŒ
Dfrieds
dfrieds.com โ€บ data-analysis โ€บ categorical-data-python-pandas.html
Categorical Data - dan_friedman_learnings
Create a pandas categorical data ... by the categories argument which is the rank of responses in the order of happy, content, or sad. ... View the data type of survey_responses. ... Create a pandas DataFrame with one column called response with the survey_responses data structure. ... Preview the first 5 rows of df_survey_responses. ... Use the describe() method on ...
๐ŸŒ
Pandas
pandas.pydata.org โ€บ pandas-docs โ€บ stable โ€บ reference โ€บ api โ€บ pandas.DataFrame.describe.html
pandas.DataFrame.describe โ€” pandas 3.0.2 documentation
>>> df.describe(include="all") categorical numeric object count 3 3.0 3 unique 3 NaN 3 top f NaN a freq 1 NaN 1 mean NaN 2.0 NaN std NaN 1.0 NaN min NaN 1.0 NaN 25% NaN 1.5 NaN 50% NaN 2.0 NaN 75% NaN 2.5 NaN max NaN 3.0 NaN
๐ŸŒ
Programiz
programiz.com โ€บ python-programming โ€บ pandas โ€บ categorical
Pandas Categorical (With Examples)
Categorical data is handy when we have data that naturally fit into predefined options. In Pandas, the Categorical() method is used to create a categorical data type from a given sequence of values.
๐ŸŒ
pandas
pandas.pydata.org โ€บ pandas-docs โ€บ dev โ€บ user_guide โ€บ categorical.html
Categorical data โ€” pandas documentation
Categoricals are a pandas data type corresponding to categorical variables in statistics. A categorical variable takes on a limited, and usually fixed, number of possible values (categories; levels in R).
๐ŸŒ
GeeksforGeeks
geeksforgeeks.org โ€บ python โ€บ python-pandas-categorical
Python | Pandas.Categorical() - GeeksforGeeks
March 10, 2022 - pandas.Categorical(val, categories = None, ordered = None, dtype = None) : It represents a categorical variable. Categorical are a pandas data type that corresponds to the categorical variables in statistics. Such variables take on a fixed and ...
๐ŸŒ
Pandas
pandas.pydata.org โ€บ pandas-docs โ€บ version โ€บ 1.0.1 โ€บ user_guide โ€บ categorical.html
Categorical data โ€” pandas 1.0.1 documentation
Categoricals are a pandas data type corresponding to categorical variables in statistics. A categorical variable takes on a limited, and usually fixed, number of possible values (categories; levels in R).
๐ŸŒ
Arabpsychology
statistics.arabpsychology.com โ€บ home โ€บ learning to analyze categorical data using pandas describe()
Learning To Analyze Categorical Data Using Pandas Describe() - PSYCHOLOGICAL STATISTICS
November 15, 2025 - By executing include='object', the analyst instructs pandas to strictly analyze only those columns whose data type matches the object indicator. For these selected columns, the describe() function intelligently switches its output format, delivering a specialized set of statistics tailored for qualitative analysis. This adapted output prioritizes insights into frequency, variety, and dominant categories, rather than traditional metrics like mean or standard deviation.
๐ŸŒ
Pandas
pandas.pydata.org โ€บ docs โ€บ dev โ€บ user_guide โ€บ categorical.html
Categorical data โ€” pandas 3.0.0rc2+1.g0d0ec6f2c0 documentation
Categoricals are a pandas data type corresponding to categorical variables in statistics. A categorical variable takes on a limited, and usually fixed, number of possible values (categories; levels in R).
๐ŸŒ
w3resource
w3resource.com โ€บ pandas โ€บ dataframe โ€บ dataframe-describe.php
Pandas DataFrame: describe() function - w3resource
The describe() function is used to generate descriptive statistics that summarize the central tendency, dispersion and shape of a datasetโ€™s distribution, excluding NaN values.