## 20-points DoE, and the corresponding response
d <- 2
nb_PX <- 20
require(DiceDesign)
x <- lhsDesign(nb_PX, d, seed = 123)$design
require(DiceKriging)
fx <- apply(x, 1, branin)
f <- ifelse(fx < 14, -1, 1)
Xf <- as.matrix(x)
## GPC model
model <- gpcm(f, Xf, coef.m=0, coef.cov=c(0.5,0.5))
## print the result
show(model)
Run the code above in your browser using DataLab