[R] Coefficient of determination for non-linear equations system (nlsystemfit)

Antti Simola asimola78 at gmail.com
Tue Nov 20 10:24:26 CET 2012


Hello everyone,

I have estimated system of three linear equations with one non-linear 
restrictions with nlsystemfit. I was wondering how I can calculate the 
R-squared (or some alternative coefficient of determination) for the 
whole system. This is automatically given by linear systemfit but not by 
nlsystemfit. I can get the values for each of the equations separately, 
but apparently not for the whole system.

I'm also wondering why separate equations' objects all appear in 
together with a command like:

nl.system <- nlsystemfit()

nl.system$eq[i]

but e.g. the following produces NULL as the value for the individual 
objects, e.g. R-squared

eq.1 <- nl.system$eq[1]

eq.1$r2

Cheers,

Antti



More information about the R-help mailing list