This function updates the training input and output of a GP or DGP emulator with an option to refit the emulator.
Usage
update(object, X, Y, refit, reset, verb, ...)
# S3 method for class 'dgp'
update(
object,
X,
Y,
refit = TRUE,
reset = FALSE,
verb = TRUE,
N = NULL,
cores = 1,
ess_burn = 10,
B = NULL,
...
)
# S3 method for class 'gp'
update(object, X, Y, refit = TRUE, reset = FALSE, verb = TRUE, ...)Arguments
- object
can be one of the following:
the S3 class
gp.the S3 class
dgp.
- X
the new input data which is a matrix where each row is an input training data point and each column represents an input dimension.
- Y
the new output data:
If
objectis an instance of thegpclass,Yis a matrix with only one column and each row being an output data point.If
objectis an instance of thedgpclass,Yis a matrix with its rows being output data points and columns being output dimensions. Whenlikelihood(see below) is notNULL,Ymust be a matrix with only one column.
- refit
a bool indicating whether to re-fit the emulator
objectafter the training input and output are updated. Defaults toTRUE.- reset
a bool indicating whether to reset hyperparameters of the emulator
objectto the initial values first obtained when the emulator was constructed. Use if it is suspected that a local mode for the hyperparameters has been reached through successive updates. Defaults toFALSE.- verb
a bool indicating if trace information will be printed during the function execution. Defaults to
TRUE.- ...
N/A.
- N
number of training iterations used to re-fit the emulator
objectif it is an instance of thedgpclass. If set toNULL, the number of iterations is set to100if the DGP emulator was constructed without the Vecchia approximation, and is set to50if Vecchia approximation was used. Defaults toNULL.- cores
the number of processes to be used to re-fit GP components (in the same layer) at each M-step during the re-fitting. If set to
NULL, the number of processes is set to(max physical cores available - 1)ifvecchia = FALSEandmax physical cores available %/% 2ifvecchia = TRUE. Only use multiple processes when there is a large number of GP components in different layers and optimization of GP components is computationally expensive. Defaults to1.- ess_burn
number of burnin steps for the ESS-within-Gibbs sampler at each I-step of the training of the emulator
objectif it is an instance of thedgpclass. Defaults to10.- B
the number of imputations for predictions from the updated emulator
objectif it is an instance of thedgpclass. This overrides the number of imputations set inobject. Set toNULLto use the same number of imputations set inobject. Defaults toNULL.
Details
See further examples and tutorials at https://mingdeyu.github.io/dgpsi-R/dev/.
Note
The following slots:
looandooscreated byvalidate();resultscreated bypredict(); anddesigncreated bydesign()
in
objectwill be removed and not contained in the returned object.
