linear model help
x y 20 399 18 323 5 26 13 170 2 3 15 220 2 5
Use the dataset and its analyses to determine whether a linear model is the best fit. Explain your reasoning.
2. Find the correlation coefficient using L1 as the x values. (1 point) • 0.9617 • 0.9807* • 20.64 • –57.44 3. Find the coefficient of determination. What percent of the variation is explained by the LSRL? (1 point) • 4% • 98% • 2% • 96%*
You don't have the equation of the line, but if you want to find the equation of the line of best fit, then: \(\large\color{black}{ \displaystyle \hat{y}=\left(r\times \frac{S_y}{S_x}\right)x+\left(\bar{y} -r\times \frac{S_y}{S_x}\times \bar{x}\right)}\)
\(\hat{y}\) is the notation for the predicated value of y (or notation for line of best fit in statistics) \(S_y\) and \(S_x\) are the deviations in y and x respectively (Doesn't matter if both are sample or population deviations) \(\bar{y}\) and \(\bar{x}\) are the mans of y list and x list respectively.
O-O
I think that it is better if you draw a scatter plot using data you provided, in order to guess the law between such data. Furthermore might be necessary drawing some graphs using logarithmic scales
Those are the notations I explained. Now want to go through finding each of the components of the line of best fit?
yes please, do you want me to make a scatterplot
For your question, I will add that if you had some line: y=mx+b which you claimed to be the line of best fit, it must satisfy two conditions to be truly best fit. [1] Sum of residuals is 0. [2] Goes through the point \(\left(\bar{x},\bar{y}\right)\)
if I am saying some too complicated stuff then I apologize.
I graphed it and it looked weird, like a wet noodle..
we can draw a scatter plot placing the \(x\) values on a horizontal line, and placing the \(y\) value on a vertical scale
ok
\(y\) values*
please what graph do you get?
let me graph again
ok!
please tag me when you have finished
@Michele_Laino
ok! It looks like that we have a quadratic function, between \(x\) and \(y\), such that \(y=0\) when \(x=0\). So, we can conjecture this function: \[\Large y = A{x^2}\] which is not helpful. nevertheless, if we take the logarithm of both sides, we get: \[\Large \log y = \log A + 2\log x\] which represent a linear dependence between \(\log y\) and \(x\)
so, you have to apply the formulas of linear fit, in order to compute the value of the constant \(\log A\). Of course, in order to do such analytical fit, you have to consider the subsequent ordered pairs: \((x,\log y)\)
the logarithm can be taken with respect to the base \(10\)
ok
@Michele_Laino what do i do now, im stuck lol
you have to draw a scatter plot, placing the \(x\) values along a horizontal scale, and placing the \( \log y\) values along a vertical scale
please try, then tag me when you have finished
@mathmate
wait what are the log y values? im sorry
@Michele_Laino
for example, If I consider the first ordered pair: \((20,399)\) you have to graph this pair: \((20, \log 399)=(20, 2.6)\) so your scatter plot has to contains this pair \((20, 2.6)\) Please do the same with the remaining ordered pairs
ok so i got the points (20,2.6) (18,2.5) (5,1.4) (13,2.3) (2,0.5) (15,2.3) (2,0.7) do i put those in a scatterplot
@Michele_Laino
please can you redo your scatter plot using these oredered pairs: \[\begin{gathered} \left( {20,2.600} \right) \hfill \\ \left( {18,2.509} \right) \hfill \\ \left( {5,1.415} \right) \hfill \\ \left( {13,2.230} \right) \hfill \\ \left( {2,0.477} \right) \hfill \\ \left( {15,2.342} \right) \hfill \\ \left( {2,0.699} \right) \hfill \\ \end{gathered} \]
ordered*
i got sort of the same graph
ok! Now you have to draw a straight line, which passes in vicinity of the most number of points
ok
thats going to be slightly difficult lol
I try to draw such straight line, please wait...
here is the straight line:
ohh ok.
now we have to search for its intercept, with the vertical axis
ok
please write the requested value:
0.76?
I think that it is greater than 0.76
thats what the green dot is on T-T
oh, im bad at this hold on a tick
0.86?
I think it is \(0.805\), I have used a proportion
so we can write this: \[\Large \log A = 0.805\] so, what is \(A=...?\)
is that the 0.805
yes!
it is the vertical intercept of the straight line
so does that mean that the linear model is the best fit?
linear model is the best fit for the logarithmic expression, since we have conjectured this realtion: \(\huge y=Ax^2\)
and \(\large A=...?\) please what is the value of \(\Large A\) if \(\Large \log A=0.805\)?
0.805? lol
is a and log a the same?
we have to do this computation: \[\Large \log A = 0.805 \Rightarrow A = {10^{0.805}} \cong 6.38\]
ohh so a=6.38?
correct!! :)
so that means the linear model is the best fit?
we can use the linear model for these variables: \(x\) and \( \log y\) so we can write: \[\Large y = 6.38{x^2}\] nevertheless it is not very precise, since, as you can see the red line doesn't fit all points, for example the first two points
then linear model is the best fit for these variables: \(\huge (x, \,\log y)\)
in confused again lol im sorry haha
because we used the data in the set, did we find weather a linear model was the best fit?
wait or because x,log y means that we did and its the linear best fit model.. im confused
no problem :) as we can see, we have applied the best fit, (red line) to these ordered pairs \((x,\,\log y)\) since we have understood that there is a quadratic relation between \(x\) and \(y\), from the first scatter plot
so that means yes that a linear model is the best fit?
yes! It is the best fit for this function: \(\log y= \log A +2x\)
Or, in other words, data you provided can not be fitted using a linear model, nevertheless, the subsequent data \((x,\,\log y)\) can be fitted by a linear model
Join our real-time social learning platform and learn together with your friends!