View source: R/posterior_inference.R
map_spatial_param | R Documentation |
Plot a map of interpolated spatially-dependent parameter values.
map_spatial_param(
out,
parameter = "slope",
loadings = 1,
type = "mean",
yearscale = TRUE,
new_x = NULL,
ci.level = c(0.025, 0.975),
fine = 100,
color.gradient = (grDevices::colorRampPalette(rev(RColorBrewer::brewer.pal(9, name =
"RdBu"))))(fine),
with.uncertainty = FALSE,
map = FALSE,
state = FALSE,
location = NULL,
addthin = 1
)
out |
Output from BSTFA or BSTFAfull. |
parameter |
One of |
loadings |
If |
type |
One of |
yearscale |
If |
new_x |
If the original model included covariates |
ci.level |
If |
fine |
Integer specifying the number of grid points along both the longitude and latitude directions used to interpolate the parameter. The resulting interpolation grid will contain |
color.gradient |
The color palette to use for the plot. Default is |
with.uncertainty |
Logical scalar indicating whether to include lower and upper credible interval bounds for the parameter. Default is |
map |
Logical scalar indicating whether to include a map. Default value is |
state |
Logical scalar used when |
location |
Name of region to include in the map. Fed to |
addthin |
Integer indicating the number of saved draws to thin. Default is to not thin any |
A plot of spatially-dependent parameter values for a grid of interpolated locations.
Adam Simpson and Candace Berrett
data(out.sm)
attach(out.sm)
map_spatial_param(out.sm, parameter='slope', map=TRUE, state=TRUE, location='utah', fine=25)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.