Re: [R] use pcls to solve least square fitting with constraints

2011-07-15 Thread sonem
Hi, I need help with imposing constraints on GAM parameters, maybe through pcls.. I have a GAM model without intercept with several strictly parametric and smooth parameters. I need to set a linear constraint such that sum of parametric coefficients and first derivatives of the smoothes is equal

Re: [R] use pcls to solve least square fitting with constraints

2010-12-06 Thread Ben Bolker
Baoqiang Cao gmail.com> writes: > I have a least square fitting problem with linear inequality > constraints. pcls seems capable of solving it so I tried it, > unfortunately, it is stuck with the following error: > > M <- list() > > M$y = Dmat[,1] > > M$X = Cmat > > M$Ain = as.matrix(Amat) > > M$

[R] use pcls to solve least square fitting with constraints

2010-12-06 Thread Baoqiang Cao
Hi, I have a least square fitting problem with linear inequality constraints. pcls seems capable of solving it so I tried it, unfortunately, it is stuck with the following error: > M <- list() > M$y = Dmat[,1] > M$X = Cmat > M$Ain = as.matrix(Amat) > M$bin = rep(0, dim(Amat)[1]) > M$p=qr.solve(as.