[R] lsqlin in pracma
    Ravi Varadhan 
    ravi.varadhan at jhu.edu
       
    Sat Aug 29 18:29:04 CEST 2015
    
    
  
In solve.QP(), you don't need to expand the equality into two inequalities.  It can DIRECTLY handle the equality constraints.  The first `meq' rows of the constraint matrix are equality constraints. Here is the excerpt from  the documentation.
meq
the first meq constraints are treated as equality constraints, all further as inequality constraints (defaults to 0).
Therefore, solve.QP() can provide the full functionality of lsqlin in Matlab.  However, one caveat is that the bounds constraints have to be implemented via inequalities in solve.QP(), which is a slight pain, but not a deal breaker.
Best,
Ravi
	[[alternative HTML version deleted]]
    
    
More information about the R-help
mailing list