simulate.deform {deform} | R Documentation |
Simulate from a fitted deform
object
Description
Simulate from a fitted deform
object
Usage
## S3 method for class 'deform'
simulate(object, nsim = 1, seed = NULL, newdata = NULL, ...)
Arguments
object |
a fitted |
nsim |
an integer giving the number of simulations |
seed |
an integer giving the seed for simulations |
newdata |
a 2-column matrix of x and y coordinates |
... |
extra arguments to pass to |
Value
Plots representing all one- or two-dimensional smooths
Examples
# deformations
data(solar)
m0 <- deform(solar$x, solar$z, solar$n)
# Gaussian process simulations based on fitted deformation model
simulate(m0)
# one-dimensional expansion model with five simulations and specified locations
data(solar)
m1 <- expand(solar$x, solar$z, solar$n)
xvals <- seq(-123.3, -122.25, by = .05)
yvals <- seq(49, 49.4, by = .05)
xyvals <- expand.grid(xvals, yvals)
simulate(m1, 5, newdata = xyvals)
[Package deform version 1.0.0 Index]