View source: R/akaike_weights.R
akaike_weights | R Documentation |
Calcola gli Akaike weights di un set di modelli.
akaike_weights( x )
x |
vettore con i valori dei criteri di informazione calcolati su un set di modelli. |
Restituisce una lista con due elementi:
$delta |
differenza tra ciascun valore del vettore di input ed il valore più basso. |
$w |
Akaike weights. |
Massimiliano Pastore
Burnham, K. P., Anderson, D. R., & Huyvaert, K. P. (2011). AIC model selection and multimodel inference in behavioral ecology: some background, observations, and comparisons. Behavioral Ecology and Sociobiology, 65 (1), 23–35.
McElreath, R. (2016). Statistical Rethinking: A Bayesian Course with Examples in R and Stan. CRC Press: Boca Raton, FL.
Wagenmakers, E.-J., & Farrell, S. (2004). AIC model selection using Akaike weights. Psychonomic bulletin & review, 11 (1), 192–196.
data(kidiq)
m0 <- lm(kid_score ~ 1, data = kidiq)
m1 <- lm(kid_score ~ mom_hs, data = kidiq)
m2 <- lm(kid_score ~ mom_iq, data = kidiq)
m3 <- lm(kid_score ~ mom_iq + mom_hs, data = kidiq)
m4 <- lm(kid_score ~ mom_iq * mom_hs, data = kidiq)
TAB <- AIC(m0,m1,m2,m3,m4)
akaike_weights(TAB[,"AIC"])
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.