Re: [R] R-squared and GLM

2013-07-18 Thread Chris89
Haha, true true! ;)

It was to be used as a measure on how good the models I use are, but I found
out that the AIC would be much easier to implement, and as I understand, a
better measure of how good the model fit.

Thanks,
Chris



--
View this message in context: 
http://r.789695.n4.nabble.com/R-squared-and-GLM-tp4671754p4671820.html
Sent from the R help mailing list archive at Nabble.com.

__
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.


Re: [R] R-squared and GLM

2013-07-17 Thread Rolf Turner

On 18/07/13 02:36, Chris89 wrote:

Dear users,

I want to compute r-squared values from a glm regression using a gamma
distribution and an "identity" link-function, but find no such thing when
using the summary() or names() function. My next guess was to calculate it
by "hand", i.e.

r2 = (sum((estimate - xbar)^2) /sum((x-xbar)^2))

but I am unsure if this is even allowed...


Who is going to disallow you?  It's a free country.  (I refer to Norway of
course; freer than most countries, in my understanding.)

But since you are maximizing a likelihood based on the Gamma distribution,
rather than doing least squares, what exactly is the relevance of R-squared
anyway?

cheers,

Rolf Turner

__
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.


[R] R-squared and GLM

2013-07-17 Thread Chris89
Dear users,

I want to compute r-squared values from a glm regression using a gamma
distribution and an "identity" link-function, but find no such thing when
using the summary() or names() function. My next guess was to calculate it
by "hand", i.e.

r2 = (sum((estimate - xbar)^2) /sum((x-xbar)^2)) 

but I am unsure if this is even allowed...

Chris





--
View this message in context: 
http://r.789695.n4.nabble.com/R-squared-and-GLM-tp4671754.html
Sent from the R help mailing list archive at Nabble.com.

__
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.