AIC.dglars: Akaike's An Information Criterion

Description Usage Arguments Details Value Author(s) References See Also Examples

View source: R/AIC.dglars.R

Description

AIC.dglars is used to compute the Akaike's ‘An Information Criterion’ for the sequence of models estimated by “dglars”.

Usage

1
2
3
4
5
6
## S3 method for class 'dglars'
AIC(object, phi = c("pearson", "deviance", "mle", "grcv"),
k = 2, complexity = c("df", "gdf"), g = NULL, ...)

## S3 method for class 'dglars'
BIC(object, ...)

Arguments

object

a fitted dglars object.

phi

a description of the estimator of the dispersion parameter (see below for more details).

k

non negative value used to weight the complexity of the fitted dglars model (see below for more details).

complexity

argument used to specify the method to measure the complexity of a fitted dglars model, i.e. the number of non-zero estimates (complexity = "df") of the generalized degrees-of-freedom (complexity = "gdf"); see below for more details.

g

vector of values of the tuning parameter.

...

further arguments passed to the function link{grcv}.

Details

The values returned by AIC.dglars are computed according to the following formula of a generic measure of Goodness-of-Fit (GoF):

-2 * log-likelihood + k * comp,

where “comp” represents the term used to measure the complexity of the fitted model, and k is the ‘weight’ of the complexity in the previous formula.

For binomial and Poisson family, the log-likelihood function is evaluated assuming that the dispersione parameter is known and equal to one while for the remaining families the dispersion parameter is estimated by the method specified by phi (see phihat for more details).

According to the results given in Augugliaro et. al. (2013), the complexity of a model fitted by dglars method can be measured by the classical notion of ‘Degrees-of-Freedom’ (complexity = "df"), i.e., the number of non-zero estimated, or by the notion of ‘Generalized Degrees-of-Freedom’ (complexity = "gdf").

By the previous formula, it is easy to see that the standard AIC-values are obtained setting k = 2 and complexity = "df" (default values for the function AIC.dglars) while the so-called BIC-values (Schwarz's Bayesian criterion) are obtained setting k = log(n), where n denotes the sample size, and complexity = "df" (default values for the function BIC.dglars).

The optional argument g is used to specify the values of the tuning parameter; if not specified (default), the values of the measure of goodness-of-fit are computed for the sequence of models storage in object otherwise predict.dglars is used to compute the estimate of the parameters needed to evaluate the log-likelihood function (see the example below).

Value

AIC.dglars and BIC.dglars return a named list with class “gof_dglars” and components:

val

the sequence of AIC/BIC-values;

g

the sequence of g-values;

loglik

the sequence of log-likelihood values used to compute the AIC or BIC;

k

the non negative value used to weight the complexity of the fitted dglars model;

comp

the measures of model complexity used to compute the measure of goodness-of-fit. It is equal to npar when codecomplexity = "df";

npar

the seqeunce of the number of non-zero estimates

phi

a description of the estimator used to estimate the dispersion pamater;

phih

the vector of penalized estimate of the dispersion parameter used to evaluate the log-likelihood function;

complexity

character specifying the method to measure the complexity of a fitted dglars model;

object

the fitted dglars object;

type

character specifying the type of used measure-of-goodness of fit, i.e., AIC, BIC or GoF.

In order to summarize the information about the AIC-valuse, a print method is available for an object with class “gof_dglars”.

Author(s)

Luigi Augugliaro
Maintainer: Luigi Augugliaro [email protected]

References

Augugliaro L., Mineo A.M. and Wit E.C. (2013) dgLARS: a differential geometric approach to sparse generalized linear models, Journal of the Royal Statistical Society. Series B., Vol 75(3), 471-498.

Sakamoto, Y., Ishiguro, M., and Kitagawa G. (1986). Akaike Information Criterion Statistics. D. Reidel Publishing Company.

See Also

logLik.dglars, predict.dglars, dglars and summary.dglars.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
#################################
# y ~ Pois

library("dglars")
set.seed(123)
n <- 100
p <- 5
X <- matrix(abs(rnorm(n*p)),n,p)
eta <- 1 + X[, 1]  + X[, 2]
mu <- poisson()$linkinv(eta)
y <- rpois(n, mu)
out <- dglars(y ~ X, poisson)
out
AIC(out)
AIC(out, g = seq(2, 1, by = -0.1))
AIC(out, complexity = "gdf")
AIC(out, k = log(n)) #BIC-values
BIC(out)

#################################
# y ~ Gamma

n <- 100
p <- 50
X <- matrix(abs(rnorm(n*p)),n,p)
eta <- 1 + 2 * X[, 1L]
mu <- drop(Gamma()$linkinv(eta))
shape <- 0.5
phi <- 1 / shape
y <- rgamma(n, scale = mu / shape, shape = shape)
out <- dglars(y ~ X, Gamma("log"))

AIC(out, phi = "pearson")
AIC(out, phi = "deviance")
AIC(out, phi = "mle")
AIC(out, phi = "grcv")

dglars documentation built on Oct. 9, 2018, 5:04 p.m.