Data for session 2: Normal equation and batch gradient descent.
Gerardo Marx b3564c4d0d data for lab session 2
Readme.md data for lab session 2
dataLab.csv data for lab session 2
plot.png data for lab session 2

Readme.md

Readme

This data file (dataLab.csv)has been collected using the TCLab board. The data was generated by using:

import time 
import tclab 
import numpy as np

n=600
t =  np.linspace(0,n-1,n)
T1 = np.empty_like(t)
with tclab.TCLab() as lab:
    lab.Q1(68)
    for i in range(n):
        T1[i] = lab.T1
        print(T1[i])
        time.sleep(1)

Then, temperature measurements are stored with

import pandas as pd
DF = pd.DataFrame(T1)
DF.to_csv("dataLab.csv", index=False)

How to use the data

To use temperature measurements, you have to load data using:

import pandas as pd
df =  pd.read_csv('dataLab.csv')
y = df['0']

If you data is plotted, it should look like the next figure:

import matplotlib.pyplot as plt
plt.plot(y, '.r')

plot