Hi,
I desire to draw a random number about the fitting of a glm model using a
quasi linear error distribution.
For example, if my family is poisson, then this is what I want:
model1 = glm(amount~days,family=poisson(link="log"),data=dataset1)
mean1 = predict(model1,newdata =data.frame(days=time),type="response")
rpois(length(mean1),mean1)
But I wish to change my model to:
model2 = glm(amount~days,family=quasi(link="log",
variance="mu"),data=dataset2)
mean2 = predict(model2,newdata =data.frame(days=time),type="response")
Is there a way to draw a random number about the mean when I have a
quasi-linear error distribution?
Thanks.