9284. Re: Rによるモデル選択 けい 2006/01/31 (火) 13:38
---以下出力結果です----
> model.glm<-glm(Rate~Habitat+Age+Sex+Habitat*Age+Sex*Habitat,family=gaussian)
> stepAIC(model)
Start: AIC= -97.97
Rate ~ Habitat + Age + Sex + Habitat * Age + Sex * Habitat
Df Sum of Sq RSS AIC
- Habitat:Sex 1 0.034 2.592 -99.452
<none> 2.559 -97.973
- Habitat:Age 1 0.275 2.834 -95.894
Step: AIC= -99.45
Rate ~ Habitat + Age + Sex + Habitat:Age
Df Sum of Sq RSS AIC
- Sex 1 0.006 2.599 -101.356
<none> 2.592 -99.452
- Habitat:Age 1 0.478 3.071 -94.680
Step: AIC= -101.36
Rate ~ Habitat + Age + Habitat:Age
Df Sum of Sq RSS AIC
<none> 2.599 -101.356
- Habitat:Age 1 0.485 3.083 -96.514
---glmのとき---
model.glm<-glm(Rate~Habitat+Age+Sex+Habitat*Age+Sex*Habitat,family=gaussian)
> stepAIC(model.glm)
Start: AIC= 17.54
Rate ~ Habitat + Age + Sex + Habitat * Age + Sex * Habitat
Df Deviance AIC
- Habitat:Sex 1 2.5924 16.0626
<none> 2.5588 17.5420
- Habitat:Age 1 2.8335 19.6209
Step: AIC= 16.06
Rate ~ Habitat + Age + Sex + Habitat:Age
Df Deviance AIC
- Sex 1 2.5986 14.1591
<none> 2.5924 16.0626
- Habitat:Age 1 3.0706 20.8353
Step: AIC= 14.16
Rate ~ Habitat + Age + Habitat:Age
Df Deviance AIC
<none> 2.5986 14.1591
- Habitat:Age 1 3.0834 19.0010
----終わり----
|