Hey.(adsbygoogle = window.adsbygoogle || []).push({});

I tried to make a function that could calculate the function of a "average" line. See my picture:

http://home1.stofanet.dk/orhan/regr.jpg

The language is danish but if you know about regression you will understand the variables. What have I done wrong?

or.han

**Physics Forums | Science Articles, Homework Help, Discussion**

Join Physics Forums Today!

The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

# Regression function

**Physics Forums | Science Articles, Homework Help, Discussion**