spflow_moran_plots | R Documentation |
Generate up to three Moran scatter plots, related to origin-, destination-, and origin-to-destination-dependence.
spflow_moran_plots(object, ...)
## S4 method for signature 'spflow_network_multi'
spflow_moran_plots(
object,
id_net_pair = id(object)[["pairs"]][[1]],
flow_var,
model = "model_9",
DW,
OW,
add_lines = TRUE
)
## S4 method for signature 'spflow_model'
spflow_moran_plots(object, model = "model_9", DW, OW, add_lines = TRUE)
object |
A |
... |
arguments passed to methods |
id_net_pair |
A character indicating the id of a |
flow_var |
A character, indicating one variable from the network pair data |
model |
A character indicating the model number, that controls different spatial
dependence structures should be one of |
DW, OW |
A matrix to replace the neighborhood of the destinations (DW) and origins (OW). Defaults to the one supplied to the model. |
add_lines |
A logical, if |
# Used with a spflow_network_multi ...
# To check the if there is spatial correlation in any variable
spflow_moran_plots(multi_net_usa_ge, "ge_ge",flow_var = "y9")
# Used with a spflow_model...
# Check the if there is spatial correlation in the residuals
gravity_ge <- spflow(
y9 ~ . + P_(DISTANCE),
multi_net_usa_ge,
"ge_ge",
spflow_control(model = "model_1"))
spflow_moran_plots(gravity_ge)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.