Guided Project: Visualizing Earnings Based On College Majors _ Part3 Histograms

Part 3:

Use the plots to explore the following questions:

What percent of majors are predominantly male? Predominantly female?
What's the most common median salary range?

I am not sure how to understand, what majors are predominantly…
recent_grads[‘ShareWomen’].hist(bins=5, range=(0,5000))

I just see one bar.

Furthermore, I have no bar at all at the Median Salary…
recent_grads[‘Median’].hist(bins=25, range=(0,5000))

Best
Andreas

Hi @ANDI,

Can you please add more information to your topic?

These articles may help you:


Thanks,
Sahil

1 Like

Guided Project_Visualizing Earnings based on College Majors.ipynb (467.7 KB)

Click here to view the jupyter notebook file in a new tab

Sorry for waiting :wink:

As you can see in my Notebook, it works, I just do not understand how to read that information. Also the solution https://github.com/dataquestio/solutions/blob/master/Mission146Solutions.ipynb doesnt help at all, since there is no markdown description.

Best
Andi

Hi @ANDI,

Please remove the bins and range arguments from the .hist() method (bins=25, range=(0,5000)). This will allow matplotlib to auto-detect the best values and thus, your plots will be produced correctly.

For the explanation part, I do agree that the solution page is not helpful as no explanation is available in this project. I had raised this issue with the content team and they are working on a rewrite of this course so this will be fixed.

To help you to understand how to interpret the results, I think these two posts will help you:

Best,
Sahil

1 Like