get_mesh | R Documentation |
Create a mesh for the US West Coast. This method provides a work around for needing a kmeans file.
get_mesh(data.inner, data.outer, numknots)
data.inner |
A data frame of points with at least two columns,
|
data.outer |
A data frame of points with at least two columns,
|
numknots |
The desired number of knots to have in the resulting mesh.
This will be approximate because the distance between points used for knots
will be used to solve to the ideal number of knots using a while loop.
Thus, expect the resulting number of knots to be within plus or minus five
percent of this input value. See |
An inla.mesh
list object created with
inla.mesh.create()
.
The resulting list has 8 default elements from INLA and a few additional
elements that are added specifically for VASTWestCoast, including the
coordinates used to create the mesh. Of most interest is probably the
meta data, which is stored in "meta"
and includes the call to
inla.mesh.create()
and the fmesher.args
used
internally. The call to get_mesh()
is also stored in "call"
.
Users can compare the desired number of knots n.desired
to the
actual number of knots n
. The number of knots should always be within
plus or minus five percent of desired number unless a solution is not
found within 100 tries, which is the current cap on the number of times
the code will run through the while
loop.
Kelli F. Johnson
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.