[R] Help for constrained linear regression
Mesomeris, Spyros [CIR]
spyros.mesomeris at citigroup.com
Mon Feb 19 17:59:25 CET 2007
Hello,
I am trying to run a constrained linear regression of a dependent
variable y on three explanatory variables x1, x2, and x3. However, I
need to constrain the coefficients of the explanatory variables as
follows: b1>0, b2<0, and b3>0.
Does anyone know how to do this within the lm/glm framework so that one
can still ask for statistics like the r-squared and t-ratios (I realize
that in this case t-stats may be harder to compute than usual and may
not be available from the lm/glm object)?
Any help would be greatly appreciated
Spyros
More information about the R-help
mailing list