Answer to your question Geoffrey Laird :
[email protected] July 2016
Disclaimer First, I want to say that I am no researcher or PhD, nothing more than a curious mind with a MSc. in Statistics and another one in Actuarial Sciences. Do not take what I say as absolute truth, do not hesitate to question what I write, especially if this is for research purpose. Finally, apologies for the poor LaTex style, I do not have much time.
Answer I note X T as the transpose matrix of X and e a unitary vector (i.e. composed of ones with an appropriate size). Considering your problem, I suggest we try to solve the following problem : w b = argminw ||Y − Xw||22 + λ eT w − 1
(1)
I do not force the sign of λ so that I can handle both inequalities at the same time. You can calculate the gradient of the associated Lagrangian : L (w) = ||Y − Xw||22 + λ eT w − 1
(2)
which is (see derivation formulas for vectors) : ∇L (w) = −2X T Y + 2X T Xw + λe
(3)
First order condition leads to :
w b
OLS,c
λ = X X X Y − e 2 −1 λ =w bOLS,u − XT X e 2 T
−1
T
(4)
where w bOLS,u is the usual, unconstrained OLS estimator. Then, we have to determine λ so that the constraint eT w bOLS,c = 1 should be verified. Then, by multiplying (left) by eT , one can get : −1 λ e 1 = eT w bOLS,u − eT X T X 2 which is equivalent to :
1
(5)
λ=2
eT w bOLS,u − 1 eT (X t X)−1 e
(6)
−1 eT w bOLS,u − 1 T X X e eT (X T X)−1 e
(7)
Finally, one can obtain : w bOLS,c = w bOLS,u −
One can check that w bOLS,c verifies the constraint. If I am not mistaken, this program answers your question to the extent that Y can be seen as being your I and the columns of the X matrix the different Ii . I suggest you include e in your X matrix. There are already topics on ResearchGate which deals with the question : Should I always include an intercept in my regression ? and the answer is yes in almost every cases. In your context, it is equivalent to consider that you have one of your Ii which does not depend on x.
2