| spm | R Documentation | 
Fit an spm model to a sspm object
spm(sspm_object, formula, ...)
## S4 method for signature 'sspm,missing'
spm(sspm_object, formula, ...)
## S4 method for signature 'sspm,formula'
spm(sspm_object, formula, ...)
| sspm_object | [sspm_dataset] An object of class sspm_dataset. | 
| formula | [formula] A formula definition of the form response ~ smoothing_terms + ... | 
| ... | Arguments passed on to  
 | 
An object of type sspm_fit.
## Not run: 
sspm_model_fit <- sspm_model %>%
    spm(log_productivity ~ sfa +
    weight_per_km2_all_predators_lag_1 +
    smooth_space(by = weight_per_km2_borealis_with_catch) +
    smooth_space(),
    family = mgcv::scat)
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.