00:01
All righty, so we have some data on the number of driver death per 100 ,000.
00:08
We're given these age ranges and the number right here.
00:14
And so we're told to pick the midpoint of the interval for the x value.
00:22
So what we do is we just take the average of the values here.
00:25
So the mean of 16 and 19 is 17 and a half, 20 and 24 is 22, 25 and 34 is 29.
00:31
And half and you go on down the line these these are our new x values and then from that we're going to make a scatter plot so rather than do the ranges this allows us to get the x of 17 and a half which is right about here corresponds to the 30 but we know that this 17 a half refers to 16 to 19 but this but in doing so and using using the midpoint, it allows us to get the least squares regression line because we can't do it with ranges.
01:08
We have to have specific x values.
01:10
So that's why we do that.
01:12
So here's the scatterplot, which seems to be going down.
01:16
And then to find the least squares regression line, we need the mean and standard evasion.
01:21
So here's the of each value.
01:23
So age is x.
01:24
Driver deaths is y.
01:26
So the mean of the age is 43, standard deviation is 24 .9, the mean of the driver deaths is 27 .3, and the standard deviation is 8 .26.
01:38
And we find the correlation coefficient.
01:40
I use this function called correl, and you input in your x values and your y values in terms of the lists, and then out pops the correlation coefficient, which is nice.
01:51
And then to get the line of best fit, b is equal to are this correlation coefficient times the standard deviation of y divided by the standard deviation in x so we get negative 0 .19 because you just substituting these values we found and then the a value is equal to y bar minus b times x bar so we just found b is negative 0 .19 multiply that by x bar which is 43 and then we subtract that from the mean of the y's so you get 35 .5 .5 8.
02:33
And, oh, let's interpret the correlation coefficient.
02:36
So it's negative .57.
02:38
So it's, it's negative.
02:40
So we definitely see that it's negative because it's going down.
02:43
Is it strong? we'd say it's moderate.
02:46
You might hear the words, you might hear the words, definitely hear negative because it's going down.
02:57
But you'll hear, i'll write this correctly, negative.
03:03
We might say moderate correlation...