scale_gauss_measure_ipTemplate: Inducing points design scaling for a Gaussian measure local...

Description Usage Arguments Details Value Author(s) References See Also Examples

View source: R/template.R

Description

Scales a design of inducing points around a Gaussian measure whose mean is the center of the design matrix and its local neighborhood. The output is an inducing points design centered at the origin that can be used as a template for predictions anywhere in the design space (with a local neighborhood of the same size). Method include scaling by a circumscribed hyperrectangle (chr) and an inverse Gaussian CDF (qnorm).

Usage

1
2
scale_gauss_measure_ipTemplate(X, N, gauss_sd, space_fill_design,
                               method = c('qnorm','chr'), seq_length=20)

Arguments

X

a matrix containing the full (large) design matrix of input locations

N

the positive integer number of Nearest Neighbor (NN) locations used to build a local neighborhood

gauss_sd

a vector of standard deviations for the Gaussian measure with with length(gauss_sd)=nrow(X). Note: at this time, the Gaussian measure must only have one nonzero standard deviation (i.e. the Gaussian measure is a slice).

space_fill_design

a matrix in [0,1]^d with M rows and number of columns = ncol(X) that is scaled and centered to create the inducing points template

method

the method by which the inducing point template is scaled. In brief, cHR ("chr") scales space_fill_design to circumscribe the neighborhood and qNorm ("qnorm") scales space_fill_design by the inverse Gaussian CDF.

seq_length

an integer that defines the sequence length used to represent the gaussian measure when building the neighbhorhood.

Details

This function is built to deal with the special class of problems where liGP is used to predict and integrate over a degenerate Gaussian measure where only one dimension has a nonzero standard deviation. Separate subroutines are called for different methods. When method=qnorm, qnormscale is called. The mean of the Gaussian distribution is the median of the design matrix. The standard deviation of the Gaussian distribution is one-third of the maximum distance from the median of the design matrix to the neighborhood points for each dimension.

For each inducing point design, the origin (i.e. predictive location) is appended to the scaled inducing point design. Thus, the resulting design contains M+1 inducing points.

Value

The output is a list with the following components.

Xm.t

a matrix of M+1 inducing points centered at the origin

Xn

a matrix of the local neighborhood at the center of the design

Xc

a matrix of the center of the design used to build the local neighborhood and inducing point template

gauss_sd

the gauss_sd used to generate the local neighborhood

time

a scalar giving the passage of wall-clock time elapsed for (substantive parts of) the calculation

Author(s)

D. Austin Cole austin.cole8@vt.edu

References

D.A. Cole, R.B. Christianson, and R.B. Gramacy (2021). Locally Induced Gaussian Processes for Large-Scale Simulation Experiments Statistics and Computing, 31(3), 1-21; preprint on arXiv:2008.12857; https://arxiv.org/abs/2008.12857

See Also

qnormscale

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
## Build up a design with N=~40K locations
x <- seq(-2, 2, by=0.02)
X <- as.matrix(expand.grid(x, x))
X_center <- apply(X, 2, median)
## Create inducing point template, first with
## circumscribed hyperrectangle (cHR) scaling
M = 10
Xm <- matrix(runif(2*M), ncol=2)

## Create template with Inverse Gaussian CDF scaling
qnorm_temp <- scale_ipTemplate(X, N=100, space_fill_design=Xm, method="qnorm")
Xm.t_qnorm <- qnorm_temp$Xm.t
Xn <- qnorm_temp$Xn


## Create template with Inverse Gaussian CDF scaling
gauss_sd <-  c(0, .05)
qnorm_temp_gauss <- scale_gauss_measure_ipTemplate(X, N=100, gauss_sd=gauss_sd,
                                             space_fill_design=Xm,
                                             method="qnorm")
Xm.t_qnorm_gauss <- qnorm_temp_gauss$Xm.t
Xn_gauss <- qnorm_temp_gauss$Xn



## View different scaled template designs
ylim <- range(Xn_gauss[,2]) + c(-.03, .05)
plot(Xn, pch=16, cex=.5, col='grey',
     xlab = 'x1', ylab = 'x2', ylim = ylim,
     main='Locally optimized IP template based on Gaussian measure')
points(Xn_gauss, cex=.7)
points(X_center[1], X_center[2], pch=16, cex=1.5)
points(Xm.t_qnorm, pch=2, lwd=2, col=3)
points(Xm.t_qnorm_gauss, pch=6, lwd=2, col=2)
legend('topleft', pch = c(16, 1, 2, 3), col = c('grey', 1, 3, 2),
       legend=c('Local neighborhood (qNorm)',
                'Local neighborhood (Gauss measure)',
                'qnorm ip design',
                'Gaussian measure ip design'))

liGP documentation built on July 17, 2021, 9:08 a.m.