1. Limited time only! Sign up for a free 30min personal tutor trial with Chegg Tutors
    Dismiss Notice
Dismiss Notice
Join Physics Forums Today!
The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

Homework Help: Root Mean Square Error, a straight line fit, and gradient issue

  1. Apr 11, 2010 #1


    User Avatar

    I have some measurements from a physics lab experiment and I am coding in Matlab a fit for the data. [Note this is not a problem with Matlab, my problem here is theory]

    In normal regression of statistics the RMSE is given by:

    [tex]s=\frac{\sigma}{\sqrt{n}} =\sqrt{\frac{\Sigma (\epsilon _i)^2}{n(n-1)}}[/tex]
    where [tex] \sigma [/tex] is the standard deviation or Root Mean Square Deviation.

    Now, according to my physics lab manual:

    "For large n the standard error of the mean implies 68% confidence interval. For small n this is not reliable and it is necessary to multiply [tex]\sigma[/tex] by a certain factor t, to obtain the appropriate confidence interval."

    They then give a table with t= 12.7 for n = 2; t = 4.3 for n =3 (t is reduced by a factor of 1/3.6 for each n)


    The root mean square error for the straight line fit is given by:
    [tex]S_{y}=\sqrt{\frac{\Sigma(\delta y_{i}^{2})}{n-2}}[/tex]

    The error in the gradient of the straight line fit is:
    [tex]S_{m}=S_{y}\sqrt{\frac{\Sigma x_{i}^{2}}{n \Sigma (x_{i}^{2})-(\Sigma x_{i})^2 }}[/tex]

    Now for my plot I have only 3 data points. They are however, very accurate. The root square is about 0.98. (the fit explains 98% of the total variation in the data about the average.)

    But the RMSE is quite large due to there being only 3 data points. My error for gradient is therefore ridiculously large. I can not find anywhere how the RMSE equation for the graph is actually derived, therefore I am having difficulty working out how/if/where I am to multiply the factor t into the RMSE equation for a straight line.

    Can anyone please help? Thanks in advance
  2. jcsd
Share this great discussion with others via Reddit, Google+, Twitter, or Facebook

Can you offer guidance or do you also need help?
Draft saved Draft deleted