Learn R Programming

lgcp (version 1.8)

matchcovariance: matchcovariance function

Description

A function to match the covariance matrix of a Gaussian Field with an approximate GMRF with neighbourhood size ns.

Usage

matchcovariance(
  xg,
  yg,
  ns,
  sigma,
  phi,
  model,
  additionalparameters,
  verbose = TRUE,
  r = 1,
  method = "Nelder-Mead"
)

Arguments

xg

x grid must be equally spaced

yg

y grid must be equally spaced

ns

neighbourhood size

sigma

spatial variability parameter

phi

spatial dependence parameter

model

covariance model, see ?CovarianceFct

additionalparameters

additional parameters for chosen covariance model

verbose

whether or not to print stuff generated by the optimiser

r

parameter used in optimisation, see Rue and Held (2005) pp 188. default value 1.

method

The choice of optimising routine must either be 'Nelder-Mead' or 'BFGS'. see ?optim

Value

...