inequality constraints and linreg (or nlls)
Posted: Tue Oct 11, 2016 8:19 am
Dear all,
I have the following problem:
I want to estimate a linear model of the form
but under the constraints that the sum of the coefficients of CYC_SUR is not negative. Someting like:
Which is the correct way to specify the inequality constraint and add them to the estimate? Is that possible with "linreg" or do I have to use "nlls"?
Thanks,
I have the following problem:
I want to estimate a linear model of the form
Code: Select all
linreg DW
# DW{1} UR_CYC_SUR{0 to 2} DLP DTOT DWS
Code: Select all
nonlin(parmset=decl) a0 b0 b1 b2 b3 b4 b5
nonlin(parmset=constr1) b0+b1+b2>=0
frml PC DW=a0*DW{1}+b0*UR_CYC_SUR+b1*UR_CYC_SUR{1}+b2*UR_CYC_SUR{2} $
+b3*DLP+b4*DTOT+b5*DWS
Thanks,