Description Usage Arguments Details Value Author(s) Examples
Maxent species distribution modeling using glmnet for model fitting
1 2 3 4 5 6 7 | maxnet(p, data, f = maxnet.formula(p, data), regmult = 1,
regfun = maxnet.default.regularization, addsamplestobackground=T, ...)
maxnet.default.regularization(p, m)
maxnet.formula(p, data, classes="default")
## S3 method for class 'maxnet'
predict(object, newdata, clamp=T, type=c("link","exponential","cloglog","logistic"), ...)
|
p |
a vector of 1 (for presence) or 0 (for background). |
data |
a matrix or data frame of predictor variables. |
f |
a formula to determine the features to be used. |
regmult |
a constant to adjust regularization. |
regfun |
a function to compute regularization constant for each feature. |
addsamplestobackground |
if T, add to the background any presence sample that is not already there. |
object |
an object of class |
newdata |
values of predictor variables to predict to. |
m |
a matrix of feature values. |
clamp |
if true, predictors and features are restricted to the range seen during model training. |
type |
type of response required. |
classes |
continuous feature classes desired, either "default" or any subset of "lqpht" (for example, "lh"). |
... |
not used. |
Using lp
for the linear predictor and entropy
for the entropy of the exponential model over the background data, the values plotted on the y-axis are:
lp
if type
is "link".
exp(lp)
if type
is "exponential".
1-exp(-exp(entropy+lp))
if type
is "cloglog".
1/(1+exp(-entropy-lp))
if type
is "logistic".
Maxnet returns an object of class maxnet
, which is a list consisting of a glmnet model with the following elements added:
betas |
nonzero coefficients of the fitted model |
alpha |
constant offset making the exponential model sum to one over the background data |
entropy |
entropy of the exponential model |
penalty.factor |
the regularization constants used for each feature |
featuremins |
minimum of each feature, to be used for clamping |
featuremaxs |
maximum of each feature, to be used for clamping |
varmin |
minimum of each predictor, to be used for clamping |
varmax |
maximum of each predictor, to be used for clamping |
samplemeans |
mean of each predictor over samples (majority for factors) |
levels |
levels of each predictor that is a factor |
Steven Phillips
1 2 3 4 5 6 7 8 |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.