[R] regression constraints?

John P. Burkett burkett at uriacc.uri.edu
Fri Jan 5 15:06:12 CET 2001

```A Bayesian approach to regression with inequality constraints on
coefficients is to first estimate the regression without constraints,
then sample from the distribution of the coefficients, discarding all
draws that violate the constraints, and finally calculate summary
statistics from the subsample that is consistent with the constraints.
Andrew Gelman et al. explain how to do that in their Bayesian Data
Analysis.  I believe they implemented their procedures in S-Plus.  If
any one has written similar programs in R, I would like very much to
hear them.

>
> "Strumila, John" wrote:
>
>> gday R gurus,
>>
>> I have a multivariate regression for which I want to constrain the
>> coefficients to be > 0.  Is this possible?
>>
>> I've check the doco and searched CRAN but can't find anything.
>>
>> thanks,
>> John Strumila
>
>
> I've been doing something like that (regression coefficients
> constrained
> to be > 0 and also forced to sum to 1) using the quadratic
> programming program solve.QP in package quadprog.
>
> -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
> r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
> Send "info", "help", or "[un]subscribe"
> (in the "body", not the subject !)  To: r-help-request at stat.math.ethz.ch
> _._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._
>
>

--
John P. Burkett
Department of Economics
University of Rhode Island