Simple Linear Regression and Area



I am wondering whether or not given a finite set of data points, and having
constructed a linear regression over the given range, the area under the
data points (assuming they are all positive) is equal to the area under the
linear regression.

This may sound stupid, and well it is stupid, but I think it can help me
illustrate my question.

Let's say you plotted data points from 0 to .1 with increments of
..001derived from a known function, lets say f(x)=x^2.
i.e. datapoints= {f(0), f(.001), f(.002)...f(.1)}

Then you performed a regression of these data points and obtained a
function:
g(x) = (B1)x +(B0);

I've done this, here are some results:
Mathematica: g(x) = -.00175+.0001*x
(Why is this g(x) in the wrong quadrant?)

Shouldn't the area of f(x) be equal to (or very close to) the area under
g(x), over the given interval {0, .1}?

They don't seem to be...

Integral[f(x), {x, 0, .1}] = .00033333

But:

Integral[g(x), {x, 0, .1}] = -.0001745

Yeah, don't know why the negative (that is to say, why the regression
computes all negative values). But curiously this is only about half the
area I expected to result. However, extended the range by an equal amount
in the negative direction (positive direction works to) and

Integral[g(x),{x,-.1,.1}] = -.00035; at least this is close...

Anyway, long story short, why do I need twice the domain for the regression
than for the actual datapoints. Surely, if the function f(x) was linear
this would not be the case, right? But I don't know why there is a
difference in this case.

Thanks for any help, insights, suggestions...overall enlightenmet.


.



Relevant Pages

  • Re: Richard Ulrich used THREE posts to distort one post in one thread
    ... That was when Richard Ulrich took it as his opening to push his ... Quackery in regression analysis. ... Those are patterns with Bob that I've noted several times. ... Linear regression might be the least ...
    (sci.stat.math)
  • Re: Regression with Dichotomous Dependent Variables
    ... A discriminant function will predict which of two groups an observation likely belongs to ... Logistic regression makes no assumptions about the predictors. ... the linear regression approach violates a cardinal assumption -- the distribution of the disturbances is now strongly related to the predictor values. ...
    (sci.stat.math)
  • LINEAR vs NONLINEAR regression
    ... A LINESR regression is a linear combinatoin of the ... > by" the model in X, in a SIMPLE LINEAR regression. ... > Here's my hand-caculation of your model and fit using the Speakeasy ... > language, using the Hamiltonian path of SWPs for the computation. ...
    (sci.stat.math)
  • Re: Simple Linear Regression and Area
    ... constructed a linear regression over the given range, ... integration and can show that your conjecture is true. ... of Quadrature formulas for numerical integration. ...
    (sci.stat.math)
  • Re: Linear Regression with Monte Carlo Simulation
    ... The result is a linear regression approximation where all of the ... I've checked residuals for all of the other standard tests..... ... forecasted value using a Monte Carlo simulation. ...
    (sci.stat.math)

Quantcast