predict_effect | R Documentation |
spflow_model-class()
The methods predict()
and predict_effect()
compute spatial predictions.
The former will return the predicted values of the dependent variables and
the later computes the change in its levels given the input data changes.
predict_effect(object, ...)
## S4 method for signature 'spflow_model'
predict(
object,
new_dat = NULL,
method = "BPA",
approx_expectation = TRUE,
expectation_approx_order = 10,
return_type = "OD",
add_new_signal = FALSE
)
## S4 method for signature 'spflow_model'
predict_effect(
object,
new_dat,
old_signal = NULL,
approx_expectation = TRUE,
expectation_approx_order = 10,
return_type = "OD",
y_is_log = FALSE
)
object |
A |
... |
not used (generic). |
new_dat |
A named list of data.frames that contain the new data.
The names should correspond to spflow_network or spflow_pair
objects contained in the |
method |
A character indicating which method to use for computing the predictions. Should be one of c("TS", "TC", "BP"). |
approx_expectation |
A logical, if |
expectation_approx_order |
A numeric, defining the order of the Taylor series approximation. |
return_type |
A character indicating the format of the returned values:
|
add_new_signal |
A logical, if |
old_signal |
A matrix that can be supplied to specify the reference value for the signal. If not given the signal contained in the model is used. |
y_is_log |
Logical, if |
The prediction methods used here have been developed or analyzed by \insertCiteGoulard2017;textualspflow. \insertCiteDargel2023;textualspflow describe how they can be adapted to the case of interaction models.
Predicted values in the format specified by the argument return_type.
-Laurent, Thibault, Paula Margaretic, and Christine ThomasâAgnan. "Generalizing impact computations for the autoregressive spatial interaction model." Geographical Analysis (2023).
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.