Okay so we've spec'd out our model and ran our first regression. 1
We did a quick sense check of what we got back and we looked at the performance of our model. 2
Now we're getting to our model evaluation stage. Evaluating and deploying the model is the final part 3
of our workflow. 4
We've done a lot of legwork up till now. 5
We formulated our question. 6
We've gathered our data. 7
We've cleaned our data. 8
We've explored and visualized our data, made sense of it. 9
We've trained our algorithm and now we're getting to the point where we can evaluate our results, refine 10
our model, look for problems, look for improvements and deploy our model. 11
So what kind of things do we do at this stage? 12
Where do we take it from here? 13
Well we're going to start by asking a series of questions about our model and about our results. 14
We're going to be checking for some problems and looking for improvements retraining our algorithm as 15
necessary. 16
The approach that we're going to take is kind of like going for a medical checkup. 17
When you go see a doctor the doctor's typically ran some tests on you. 18
Right? 19
They measure your height, your weight, listen to your breathing, take an X-ray, measure your blood pressure, 20
measure your heart rate, 21
run a blood test, hit your knee with a tiny little hammer and so on. 22
The point I'm trying to make is that the doctor will look at various stats to make their diagnosis. 23
They will look at these stats, 24
they will check if these stats are too high or too low, 25
if there's a problem, all in light of your overall condition. 26
Now it turns out that, just like your body, a regression model also has a number of stats that we can 27
look at. 28
In fact there are loads and loads of statistics that we can look at, 29
like a scary amount. 30
But my goal is to show you a couple of these statistics that are relevant to our regression model and 31
also show you how to interpret them and how to make sense of them. 32
The first one we're already quite familiar with because we've looked at r-squared extensively, but as 33
part of this evaluation process I want to introduce you to several other stats as well. 34
For example the p-values of the coefficients, the variance inflation factor and the Bayesian information 35
criterion. 36
We're going to dip our toes into the murky waters of statistics and get a taster for how to evaluate 37
a regression model.