Introduction to Grouping
In this lesson, you will be introduced to the concept of grouping related items in Pandas.
We'll cover the following...
Concept
The ability to group or segment DataFrames
by one or more columns is one of the key features of any data analysis application. Therefore it would most likely show up in a data analysis interview or task.
The idea is to divide a DataFrame
into multiple groups to analyze each group separately.
Syntax
As a reminder, the syntax is as simple as
df.groupby(<col_name>)
...