...

/

Getting the Data and Visualizing Datasets Using Scatter Plots

Getting the Data and Visualizing Datasets Using Scatter Plots

Learn how to get data from different sources and use Jupyter notebook to run python scripts to get data and how to visualize datasets using scatter plots.

Get the data

You can get up-to-date GDP data by country from many sources. We’ll want our data broken down to the per capita level because that’s the best way to get valuable apples-to-apples comparisons between countries of different sizes.

Get data from the World Bank site

We got our GDP data from the World Bank’s site and our Index of Economic Freedom data from here. Here’s how all the basic setup works.

Press + to interact
import pandas as pd
import numpy as np
import matplotlib as plt
import matplotlib.pyplot as plt
gdp = pd.read_csv('WorldBank_per_capita_GDP.csv')
ec_index = pd.read_csv('economicdata.csv')
print (gdp)

Running GDP shows us that the GDP data set has 248 rows that include plenty of ...