I'm trying to use the function glm from the MASS package to do the following fit.
fit <- glm(FP ~ rand, data = tab, family = poisson(link = "identity"), subset = rand >= 1)
(FP is >= 0)
but I get the following error
Error: no valid set of coefficients has been found:please supply starting values
In addition: Warning message:
NaNs produced in: log(x)
in contrast if I fit a model without intercept
fit <- glm(FP ~ rand - 1, data = tab, family = poisson(link = "identity"), subset = rand >= 1)
everything goes fine.
Now my guess is that the points "naturally" have a negative intercept so the error is produced because I'm using the poisson distribution for the y and negative values are of course not admitted. Am I right?
Also if this is the cause, shouldn't the function always try to do the best fit given the parameters? I mean shouldn't it fit a model with intercept 0 anyway and report it as a bad fit?
Thanks
Federico
______________________________________________ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
