[R] paraPen in gam [mgcv 1.4-1.1] and centering constraints

Daniel Sabanés Bové daniel.sabanesbove at campus.lmu.de
Sat Feb 7 22:00:32 CET 2009


Dear Mr. Simon Wood, dear list members,

I am trying to fit a similar model with gam from mgcv compared to what I
did with BayesX, and have discovered the relatively new possibility of
incorporating user-defined matrices for quadratic penalties on
parametric terms using the "paraPen" argument. This was really a very
good idea!

However, I would like to constraint the coefficients belonging to one
penalty matrix to sum to zero. So I would like to have the same
centering constraint on user-defined penalized coefficient groups like
it is implemented for the spline smoothing terms. The reason is that I
have actually a factor coding different regions, and the penalty matrix
results from the neighborhood structure in a Gaussian Markov Random
Field (GMRF). So I can't choose one region as the reference category,
because then the structure in the other regions would not contain the
same information as before...

Is there a way to constraint a group of coefficients to sum to zero?

Thanks in advance,
Daniel Sabanes




More information about the R-help mailing list