help with obtaining fitted values?
by Meredith, Christy S -FS
Hello I am having trouble finding the fitted values from Zelig. I ultimately want to use my models to predict on a new dataset and then be able to extract the fitted values to determine how well my model performs. I have tried varies methods in the documentation, but nothing works for me. I appreciate any help.
Thanks!
Christy Meredith
My code:
z.out=zelig(beavpres~Grad+Elev + distancew+Elev + GrazingR+AvgPrecip+deciduous+Bf+AvgVWidth*Grad,data=update5a,model="relogit",tau=0.05)
cv.out=cv.glm(z.out,data=update5a) # try cross validation
x.out <- setx(z.out)
s.out <- sim(z.out,x.out)
#attempt to determine fitted values- doesn't work
s.out$qi$ev
z.out$fitted.values
Christy Meredith
USDA Forest Service
Rocky Mountain Research Station
PIBO Monitoring
Data Analyst
Voice: 435-755-3573
Fax: 435-755-3563
This electronic message contains information generated by the USDA solely for the intended recipients. Any unauthorized interception of this message or the use or disclosure of the information it contains may violate the law and subject the violator to civil or criminal penalties. If you believe you have received this message in error, please notify the sender and delete the email immediately.