This package contains tools to fit point process models with sequences of LASSO penalties ("regularisation paths"). Regularisation paths of Poisson point process models or area-interaction models can be fitted with LASSO, adaptive LASSO or elastic net penalties. A number of criteria are available to judge the bias-variance tradeoff.
The key functions in ppmlasso are as follows:
Useful pre-analysis functions:
Determine the optimal spatial resolution at which to perform analysis
Set up a regular grid of quadrature points
Interpolate environmental data to species presence locations
Calculate observation weights and set up design matrix for fitting
Calculate interpoint interactions for fitting area-interaction models
Creating regularisation paths of point process models:
Fit a regularisation path of point process models
Print output from a
Make predictions from a fitted point process model to new data
Create diagnostic residual plots of
Create simulation envelope for goodness-of-fit checks on a
Ian W. Renner
Maintainer: Ian W. Renner <Ian.Renner@newcastle.edu.au>
Renner, I.W. & Warton, D.I. (2013). Equivalence of MAXENT and Poisson point process models for species distribution modeling in ecology Biometrics 69, 274-281.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22
# Fit a regularisation path of Poisson point process models data(BlueMountains) sub.env = BlueMountains$env[BlueMountains$env$Y > 6270 & BlueMountains$env$X > 300,] sub.euc = BlueMountains$eucalypt[BlueMountains$eucalypt$Y > 6270 & BlueMountains$eucalypt$X > 300,] ppm.form = ~ poly(FC, TMP_MIN, TMP_MAX, RAIN_ANN, degree = 2, raw = TRUE) ppm.fit = ppmlasso(ppm.form, sp.xy = sub.euc, env.grid = sub.env, sp.scale = 1, n.fits = 20) # Fit a regularisation path of area-interaction models data(BlueMountains) ai.form = ~ poly(FC, TMP_MIN, TMP_MAX, RAIN_ANN, degree = 2, raw = TRUE) ai.fit = ppmlasso(ai.form, sp.xy = sub.euc, env.grid = sub.env, sp.scale = 1, family = "area.inter", r = 2, availability = BlueMountains$availability, n.fits = 20) # Print a ppmlasso object print(ppm.fit, out = "model") # Residual plot of a ppmlasso object diagnose(ppm.fit, which = "smooth", type = "Pearson") # Make predictions pred.mu = predict(ppm.fit, newdata = sub.env)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.