[R] non-negative least squares

Tobias Verbeke tobias.verbeke at gmail.com
Mon Sep 8 15:00:27 CEST 2008


Terry Therneau wrote:

>  I have a problem whose solution requires non-negative least squares.  That is
>  	minimize sum(y - Xbeta)^2   subject to beta >=0
>  	
> Splus has the nnls.fit command.  Is there an R alternative?

There is a package nnls on CRAN by Kate Mullen and Ivo van Stokkum:

http://cran.r-project.org/web/packages/nnls/index.html

HTH,
Tobias



More information about the R-help mailing list