Thank you very much Dr. Brian -- I appreciate your response. I understand the idea of building the constraints into the equation but my problem is that i have to deal with potentially hundreds of dummy variables, and I want the sum of their estimates to equal zero, so LS can be fitted with an intercept and a singular X'X matrix - moreover, in different regressions the number of dummies is also potentially different so i was hoping to use some restrictions of the form R*beta = 0, where R is the matrix of restrictions and beta the dummy parameters. I have written my own estimator based on Greene and Seeks (REView of Economics and STATistics, 1991), but wanted to know if there was a package out there making things easier.
Nelson Villoria On Sat, Aug 16, 2008 at 2:24 AM, Prof Brian Ripley <[EMAIL PROTECTED]> wrote: > On Sat, 16 Aug 2008, Nelson Villoria wrote: > >> Dear R experts: >> >> Is there any package that estimates Restricted Least Squares? >> >> Specifically, If I want to fit: >> >> G = b0 + b1(Y) + a1(X1) + a2(X2) + a3(X3) + a4(X4) >> where Y, X1 to X4 are variables and b's and a's parameters to be >> estimated. >> >> I want to impose a1 + a2 + a3 + a4 = 0. > > You don't need a package to do that, just re-parametrize. It is > > G ~ Y + I(X1-X4) + I(X2-X4) + I(X3-X4) > > -- > Brian D. Ripley, [EMAIL PROTECTED] > Professor of Applied Statistics, http://www.stats.ox.ac.uk/~ripley/ > University of Oxford, Tel: +44 1865 272861 (self) > 1 South Parks Road, +44 1865 272866 (PA) > Oxford OX1 3TG, UK Fax: +44 1865 272595 > ______________________________________________ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.