AIC {VLMCX} | R Documentation |
Akaike Information Criteria for VLMCX
objects that compose Variable Length Markov Chains with Exogenous Covariates
Description
Computes the Akaike Information Criteria for the data using the estimated parameters of the multinomial logistic regression in the VLMCX fit.
Usage
AIC(fit)
Arguments
fit |
a betaVLMC object. |
Value
a numeric value with the corresponding AIC.
Author(s)
Adriano Zanin Zambom <adriano.zambom@csun.edu>
Examples
set.seed(1)
n = 1000
d = 2
X = cbind(rnorm(n), rnorm(n))
p = 1/(1 + exp(0.5 + -2*X[,1] - 3.5*X[,2]))
y = c(sample(1:0,1), rbinom(n,1, p))
fit = maximum.context(y[1:n], X, max.depth = 3, n.min = 25)
draw(fit)
AIC(fit)
##[1] 563.5249
fit = VLMCX(y[1:n], X, alpha.level = 0.001, max.depth = 3, n.min = 25)
draw(fit)
AIC(fit)
##[1] 559.4967
[Package VLMCX version 1.0 Index]