REGRDIAGNOSTICS: Diagnostics of regressions In nsRFA: Non-Supervised Regional Frequency Analysis

Description

Diagnostics of the output of lm, that is used to fit linear models.

Usage

 1 2 3 4 5 6 7 8 9 10 R2.lm (x) prt.lm (x) mantel.lm (x, Nperm = 1000) vif.lm (x) RMSE.lm (x) MAE.lm (x) predinterval.lm (x, level = 0.95) jackknife1.lm (x) RMSEjk.lm (x) MAEjk.lm (x)

Arguments

 x object of class “lm” (output of ‘lm’) Nperm number of permutations level significance level

Details

mantel.lm is performed under the assumption that the dependent distance matrix is variable, while the independent distance matrices are fixed and measured without error (they are not related to random variables, see Smouse et al., 1986). Under this assumption, the significance of the regression between distance matrices can be evaluated simultaneously permuting the rows and corresponding columns in only the dependent distance matrix, while the others are held constant.

Value

R2.lm returns the coefficient of determination R^2 and the adjusted coefficient of determination R^2_{adj} of the regression.

prt.lm returns the probability Pr(>|t|) of the significance test (Student t) of the independent variables. If the value is 0.06 for a regressor, its coefficient is not significantly different from 0 for a test with significance level of 5%.

mantel.lm returns the probability P of the Mantel test on every variable conditionated to the others. It substitutes prt.lm when dealing with distance matrices. If P is, for example, 0.92, the variable should be considered significant with significance level greater of 8%.

vif.lm returns the variance inflation factors (VIF) of the independent values of the regression. If VIF > 5 (or 10) there is a problem of multicollinearity.

RMSE.lm returns the root mean squared error of the regression.

MAE.lm returns the mean absolute error of the regression.

predinterval.lm returns the prediction intervals at a specified level in correspondence to the fitted data.

jackknife1.lm returns predicted values by a jackknife (cross-validation) procedure. The procedure (remove 1 observation, fit the model, estimate in the removed point) is repeated for all the points.

RMSEjk.lm returns the root mean squared error of the cross-validation (performed with jackknife1.lm).

MAEjk.lm returns the mean absolute error of the cross-validation (performed with jackknife1.lm).

Note

For information on the package and the Author, and for all the references, see nsRFA.