ESL2D {DynamicGP} | R Documentation |
Expected Squared L_2
Discrepancy Approach for Estimating the
Solution to the Inverse Problem
Description
This function fits an SVD-based GP model on the
training dataset design
and response matrix resp
, and
minimizes the expected squared L_{2}
discrepancy on the
test set candidate
to estimate the solution to the inverse
problem. The details are provided in Chapter 4 of Zhang (2018).
Usage
ESL2D(design,resp,yobs,candidate,frac=.95,nstarts=5,
mtype=c("zmean","cmean","lmean"),
gstart=0.0001)
Arguments
design |
An |
resp |
An |
yobs |
A vector of length |
candidate |
An |
frac |
The threshold in the cumulative percentage criterion to select the number of SVD bases. The default value is 0.95. |
nstarts |
The number of starting points used in the numerical maximization of
the posterior density function. The larger |
mtype |
The type of mean functions for the GP models. The choice "zmean" denotes zero-mean, "cmean" indicates constant-mean, "lmean" indicates linear-mean. The default choice is "zmean". |
gstart |
The starting number and upper bound for estimating the
nugget parameter. If |
Value
xhat |
The estimated solution to the inverse problem obtained from the
candidate set |
.
Author(s)
Ru Zhang heavenmarshal@gmail.com,
C. Devon Lin devon.lin@queensu.ca,
Pritam Ranjan pritamr@iimidr.ac.in
References
Zhang, R. (2018) Modeling and Analysis of Dynamic Computer Experiments, PhD thesis, Queen's University, ON, Canada.
See Also
Examples
library("lhs")
forretal <- function(x,t,shift=1)
{
par1 <- x[1]*6+4
par2 <- x[2]*16+4
par3 <- x[3]*6+1
t <- t+shift
y <- (par1*t-2)^2*sin(par2*t-par3)
}
timepoints <- seq(0,1,len=200)
design <- lhs::randomLHS(30,3)
candidate <- lhs::randomLHS(500,3)
candidate <- rbind(candidate,design)
## evaluate the response matrix on the design matrix
resp <- apply(design,1,forretal,timepoints)
x0 <- runif(3)
y0 <- forretal(x0,timepoints)
yobs <- y0+rnorm(200,0,sd(y0)/sqrt(50))
xhat <- ESL2D(design,resp,yobs,candidate,nstarts=1)
yhat <- forretal(xhat,timepoints)
## draw a figure to illustrate
plot(y0,ylim=c(min(y0,yhat),max(y0,yhat)))
lines(yhat,col="red")