LKrigSetupLattice: Creates the lattice information for a specific geometry.

Description Usage Arguments Details Value Author(s) See Also

View source: R/LKrigSetupLattice.R

Description

Given a specific geometry and the initial information supplied in an LKinfo list create the information that is needed to define the lattice for a given model. This function is required for any new geometry added to LatticeKrig.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
LKrigSetupLattice(object, ...)
## Default S3 method:
LKrigSetupLattice(object, ...)

## S3 method for class 'LKBox'
LKrigSetupLattice(object, verbose,...)
 
## S3 method for class 'LKRectangle'
LKrigSetupLattice(object, verbose,...)

## S3 method for class 'LKInterval'
LKrigSetupLattice(object, verbose,...)

 ## S3 method for class 'LKRing'
LKrigSetupLattice(object, verbose,...)
 
## S3 method for class 'LKCylinder'
LKrigSetupLattice(object, verbose,...)

 ## S3 method for class 'LKSphere'
LKrigSetupLattice(object, x = NULL, verbose,...)
    

Arguments

object

A list that is an LKinfo object.

verbose

If TRUE print out intermediate information for debugging.

x

Locations of the observations that define spatial domain. For LKSphere locations are in lon/lat degrees.

...

Any additional arguments.

Details

This method takes the LKInfo object and the other arguments and computes the lattice information needed for a specific geometry. The functions are called from within LKrigSetup and the results are added as a component tolatticeInfo as part of the LKinfo object. The way to design what should be in latticeInfo is to keep in mind that creating the spatial AR matrix (LKrigSAR) and determining the multi-resolution lattice points (LKrigLatticeCenters) use the information in the LKinfo object.

Because the lattice must depend on the geometry the default method just prints out an error message.

NC and NC.buffer for Cartesian geometries (e.g. LKInterval, LKRectangle, LKBox, LKRing) are parameters to specify to number of the grid points in the largest dimension of the spatial domain and for the coarsest lattice. These should already be a component in the LKinfo object, object specified in the usage.

For LKInterval this is just of lattice points at the coarsest level. For LKRectangle and LKBox if the spatial domain has the same size in all dimensions then the number of lattice points within the spatial domain are NC^2 and NC^3 respectively. Note that the total number of lattice points at a given level is also effected the size of NC.buffer (see below).

The number of lattice points to add to the margins beyond the spatial domain is controlled by NC.buffer. Thus in the largest spatial dimension there are a total of NC + NC.buffer*2 grid points. This is the number of lattice points for LKInterval.

Value

For the LKInterval, LKRectangle, LKBox geometries. A list with required components:

m

The total number of lattice points. i.e. the total number of basis functions.

mx

A matrix giving the number of lattice points in each coordinate (columns) and at each level (rows) of the multi-resolution.

offset

When the lattice points are unrolled as a single array, a vector of indexes giving the start of each lattice level in the coefficient vector.

delta

A vector of the lattice point spacings for each level.

rangeLocations

Limits of spatial domain.

mLevel

A vector giving number of lattice points at each level.

In addition, the methods for Cartesian and cartesian-like spatial domains ( LKInterval, LKRectangle, LKBox, LKRing, LKCylinder, LKSphere) include the additional components:

mx

A matrix giving number of grid points at each level and for each dimension.

mLevelDomain

Same as mLevel but restricted to lattice points within the spatial domain.

mxDomain

Same as mx but restricted to the points within the spatial domain.

NC

Passed value.

NC.buffer

Passed value.

grid

A list where each component is also list giving the grid points of the lattice in each coordinate.

LKSphere also returns the additional component grid3d – the direction Cosines of the grid points.

Author(s)

Doug Nychka

See Also

LKGeometry LKrigSetup, LKrigSAR, LKrigLatticeCenters


LatticeKrig documentation built on Nov. 9, 2019, 5:07 p.m.