Dear R-users,
i try to use the following code to do a gamma regression
glm(x1 / x2 ~ x3 + x4 + x5 + x6 + x7 + x8, family=Gamma(link="log"),
weights=x2)
but here i get the error
Error: NA/NaN/Inf in foreign function call (arg 1)
In addition: Warning message:
step size truncated due to divergence
x2 has integer values ranging from 1 to 6.
If i do instead
glm(x1 / x2 ~ x3 + x4 + x5 + x6 + x7 + x8, family=Gamma(link="log"))
without using the weights-argument i get no error.
So far i don't really understand what this argument realy does, what is
the difference in the results? What can i do to locate the root of the
error and how can i avoid this error? Can i to the regression without
the weights argument?
Thanks and best regards
Andreas
______________________________________________
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.