image_output_1.png
import matplotlib.pyplot as plt

import pandas as pd

df = pd.read_csv('../input/batchgradientdescent/ex1data1.csv', header=None)
df

df.columns = ['Population of City in 10,000s', 'Profit in £10,000s']

plt.xlabel('Population in city in 10,000s')
plt.ylabel('Profit in £10,000s')
plt.title('Relationship between city size and profit size')
plt.plot(df.iloc[:, 0], df.iloc[:, 1], 'ro', mec='k')
plt.legend(['Dataset'])