get_spatial_predictors {spatialRF} | R Documentation |
Gets the spatial predictors of a spatial model
Description
Returns spatial predictors from a model fitted with rf_spatial()
in order of importance.
Usage
get_spatial_predictors(model)
Arguments
model |
A model fitted with |
Value
A data frame with the spatial predictors included in the model.
Examples
if(interactive()){
#loading example data
data(distance_matrix)
data(plant_richness_df)
#fittind spatial model
model <- rf_spatial(
data = plant_richness_df,
dependent.variable.name = "richness_species_vascular",
predictor.variable.names = colnames(plant_richness_df)[5:21],
distance.matrix = distance_matrix,
distance.thresholds = c(0, 1000),
n.cores = 1,
method = "mem.moran.sequential"
)
#getting data frame with the selected spatial predictors
spatial.predictors <- get_spatial_predictors(model)
head(spatial.predictors)
}
[Package spatialRF version 1.1.4 Index]