Re: [R] GAM with constraints

2007-11-30 Thread Simon Wood
> > Are you interested in equality constraints or inequality constraints? > > No, I am interested in 2 kinds of inequality constraints: > 1) monotonic splines > 2) positive coefficients of the variables, which are not splines. > It seems that pcls should be able to deal with both of them, if smoot

Re: [R] GAM with constraints

2007-11-28 Thread lubaroz
Simon Wood-4 wrote: > > Are you interested in equality constraints or inequality constraints? > No, I am interested in 2 kinds of inequality constraints: 1) monotonic splines 2) positive coefficients of the variables, which are not splines. It seems that pcls should be able to deal with both o

Re: [R] GAM with constraints

2007-11-27 Thread Simon Wood
Are you interested in equality constraints or inequality constraints? mgcv::gam will allow you to supply your own smooths (see e.g. ?p.spline), and the specification mechanism allows you to supply linear equality constraints that the smooth must satisfy, which are then handled automatically. Whe

[R] GAM with constraints

2007-11-25 Thread lubaroz
Hi, I am trying to build GAM with linear constraints, for a general link function, not only identity. If I understand it correctly, the function pcls() can solve the problem, if the smoothness penalties are given. What I need is to incorporate the constraints before calculating the penalties. Can