Learn R Programming

LatticeKrig (version 9.3.0)

LKrigSAR: Method that creates the spatial autoregressive (SAR) matrix.

Description

Using the information in LKinfo create the SAR matrix for a given level of the multi-resolution.

Usage

LKrigSAR(object, ...)
  # S3 method for default
LKrigSAR(object, ...)
  # S3 method for LKInterval
LKrigSAR(object, Level, ...)
  # S3 method for LKRectangle
LKrigSAR(object, Level, ...)
  # S3 method for LKBox
LKrigSAR(object, Level, ...)
  # S3 method for LKRing
LKrigSAR(object, Level, ...) 
  # S3 method for LKCylinder
LKrigSAR(object, Level, ...)
   # S3 method for LKSphere
LKrigSAR(object, Level, ...)

Value

A matrix in the sparse matrix format, spind, with dimensions given by the number of lattice points at Level. Because this construction is geometry dependent the default version of this method just returns an error message.

Arguments

object

An LKinfo object.

Level

The level of the multi-resolution.

...

Any additional arguments to pass to this method.

Author

Doug Nychka

Details

The model for the Gaussian Markov Random field, c, at a given level is

B c = e,

where B is the SAR matrix computed by this method, and e are uncorrelated N(0,1). The precision matrix for this level is

Q= t(B)%*% B

and so the covariance matrix for c is the inverse of Q:

solve( Q)= solve(B)%*% t( solve(B))

See Also

LKrig.precision,spind2full

Examples

Run this code
    x<- cbind( c(0,1))
	LKinfo<- LKrigSetup(x,LKGeometry="LKInterval",
	               nlevel=3, NC=3, a.wght=5, alpha=c(1,.5,.2) )
	B<- LKrigSAR( LKinfo, Level=2)
	B<-spind2full(B)
	image.plot( B)
	
	LKinfo<- LKrigSetup(cbind( c(0,360), c(0,1)) ,LKGeometry="LKRing",
	               nlevel=1, NC=3, a.wght=5, alpha=1)
	B<- LKrigSAR( LKinfo, Level=1)
	B<-spind2full(B)
	image.plot( B)

Run the code above in your browser using DataLab