I have the following DataFrame:
I'd like to display the number of people who are single with management positions that do and do not own their own homes, in a series. I currently have the following code:
df['housing'].groupby([df['marital'], df['job']]).value_counts()
However this is currently counting the number of homeowners/non-homeowners per job and marital status. I'm only concerned with the single people with management positions.
How can I apply a filter to the resulting series so it only shows the data I am interested in?