Created
December 13, 2017 19:44
-
-
Save IanCarrasco/fd440a3763a80e1705a1fd3c362c212a to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
%matplotlib inline | |
from matplotlib import pyplot as plt | |
import numpy as np | |
import pandas as pd | |
plt.style.use('fivethirtyeight') | |
x = np.linspace(0, 10) | |
data = pd.read_csv('whr2017.csv') | |
# Fixing random state for reproducibility | |
fig, ax = plt.subplots() | |
ax.scatter(data["Log GDP per capita"],data["Healthy life expectancy at birth"],color="teal") | |
ax.set_title("GDP vs. Life Expectancy") | |
ax.set_xlabel("Log GDP") | |
ax.set_ylabel("Life Expectancy") | |
fig.set_size_inches(12.5, 7.5) | |
fig.savefig('test4png.png', dpi=100) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment