Kriging::leaveOneOut
Description
Get the Minimized Leave-One-Out Sum of Squares of a Kriging
Model
Usage
Python
# k = Kriging(...) k.leaveOneOut()
R
# k = Kriging(...) k$leaveOneOut()
Matlab/Octave
% k = Kriging(...) k.leaveOneOut()
Value
The minimized Leave-One-Out (LOO) sum of squares
\(\texttt{SSE}_{\texttt{LOO}}\), corresponding to the estimated value
\(\widehat{\theta}\) of the vector of correlation ranges. See
leaveOneOutFun.Kriging
for more details.
Examples
f <- function(x) 1 - 1 / 2 * (sin(12 * x) / (1 + x) + 2 * cos(7 * x) * x^5 + 0.7)
set.seed(123)
X <- as.matrix(runif(10))
y <- f(X)
k <- Kriging(y, X, kernel = "matern3_2", objective="LOO")
print(k)
k$leaveOneOut()
Results
* data: 10x[0.0455565,0.940467] -> 10x[0.194057,1.00912]
* trend constant (est.): 0.406331
* variance (est.): 0.118139
* covariance:
* kernel: matern3_2
* range (est.): 0.284722
* fit:
* objective: LOO
* optim: BFGS
[1] 0.003159176