Geoscience Reference
In-Depth Information
a
b
Fig. 4.7
Histogram of
a
, the i rst (slope of the regression line) and
b
, the second (
y
-axis
intercept of the line) regression coei cient, as estimated from jackknife resampling. Note that
the parameters are not as well dei ned as those from bootstrapping.
median(p(:,1))
median(p(:,2))
ans =
5.3663
ans =
21.7964
subplot(1,2,1), histogram(p(:,1)), axis square
subplot(1,2,2), histogram(p(:,2)), axis square
h e results are identical to those obtained using the code introduced
above. We have seen therefore that resampling using either the jackknife
or the bootstrap method is a simple and valuable way to test the quality of
regression models. h e next section introduces an alternative approach for
quality estimation, which is much more commonly used than the resampling
methods.
4.7 Cross Validation
A third method to test the quality of the result of a regression analysis involves
cross validation
. h e regression line is computed by using
n
-1 data points.
h e
n
th data point is predicted and the discrepancy between the prediction
and the actual value is computed. h e mean of the discrepancies between the
actual and predicted values is subsequently determined.
In this example the cross validation is computed for
n
=30 data points.