Questions

Forum Navigation
Please to create posts and topics.

Python - Describe a single column in a Dataframe

Is there a way we can apply df.describe() to just an isolated column in a DataFrame.

For example if we have several columns and we use df.describe(), it returns and describes all the columns.

Is there a way to use describe() function and apply it only to a single column in a dataframe?

To use describe() function on a single column in a dataframe, just add column name in square braquets, for example:

df['column_name'].describe()