Dear all
I have a panel dataset as follow:
ID: a a a a b b b b c c c
time: 1 2 3 4 1 2 3 4 1 2 3
x value: 5 6 7 8 1 2 3 4 3 4 5
y value: 9 11 12 17 7 8 9 10 7 6 5 4
First I need to run a regression for each ID with x as independence and y as dependence variables. Then I need to generate residuals, which is the difference between the estimated y from the regression and the actual y.
Is there any ways to to this without manually type in the intercepts and coefficients?
Thank you in advanced
I have a panel dataset as follow:
ID: a a a a b b b b c c c
time: 1 2 3 4 1 2 3 4 1 2 3
x value: 5 6 7 8 1 2 3 4 3 4 5
y value: 9 11 12 17 7 8 9 10 7 6 5 4
First I need to run a regression for each ID with x as independence and y as dependence variables. Then I need to generate residuals, which is the difference between the estimated y from the regression and the actual y.
Is there any ways to to this without manually type in the intercepts and coefficients?
Thank you in advanced
Comment