[R] User defined GLM?

Emmanuel Charpentier charpent at bacbuc.dyndns.org
Mon Jun 22 21:50:47 CEST 2009


Le lundi 22 juin 2009 à 09:35 -0700, francogrex a écrit :
> Hello, I have this generalized linear formula:
> log(x[i]/n[i])=log(sum(x)/sum(n)) + beta[i]

I do not understand the problem as stated. if x[i] and n[i] are known,
and unless sum(n)=0, your dataset reduces to a set of nrow(dataset)
independent linear equations with nrow(dataset) unknowns (the beta[i]),
whose solution is trivially beta[i]=log(x[i]/n[i])-log(sum(x)/sum(n),
except when n[i]=0 in which case your equation has no solution.

Could you try to re-express your problem ?

					Emmanuel Charpentier




More information about the R-help mailing list