Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1of 1

Name

MANGLO, JOHN ANDRAE B. APPLIED DATA SCIENCE

WORKSHEET #5: DATA VISUALIZATION WITH PYTHON

5 Date: January 13, 2020


Prepare subplots for the Engineering and Math and Statistics degrees awarded to women from 1970 to 2010. Place the
Engineering plot on top of the Math and Statistics plot. Add the following line prior to the show() command:
plt.tight_layout()

Write the code here and submit a copy of the output through Cardinal Edge Worksheet Submission.
Code
plt.subplot(2,1,1)
plt.plot(year, engineering, 'red')
plt.title('Engineering')
plt.xlabel('Year')
plt.ylabel('Degrees Awarded (%)')
plt.subplot(2,1,2)
plt.plot(year, ms,'blue')
plt.title('Math and Statistics')
plt.xlabel('Year')
plt.ylabel('Degrees Awarded (%)')
plt.tight_layout()
plt.show()

Output

Page 1 of 1

You might also like