Description Usage Arguments Value Examples
Returns the posterior mean and variance of a set of data points under a given Gaussian process
1 2 |
gp.obj |
A trained gaussianProcess object |
data |
Data to predict |
a list containing named elements:
mean
- the predicted mean value for each data point in data
.
var
- the variance about the predicted mean for each data point in data
.
1 2 3 4 5 6 7 8 9 | x <- rnorm(50)
y <- sin(1/(x^2 + 0.15))
mt <- create.model.tree.builtin()
mt <- insert.kernel.instance(mt, 1, "SE", NULL, hyper.params=c(l=1))
gp <- create.gaussian.process(x, y, mt)
gp$fit.hyperparams(NA)
x1 <- rnorm(50)
y1.predicted <- predict(gp, x1)$mean
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.