[R] pcse package - is it OK to use it when my regression is weighted by each subgroup's mean
Dimitri Liakhovitski
dimitri.liakhovitski at gmail.com
Fri Jun 18 19:32:58 CEST 2010
Hello!
Just would like to make sure I am not doing something wrong.
I am running an OLS regression. I have several subgroups in the data
set (locations) - and in each location I have weekly data for 2 years
- on my DV and on all predictors. Looks like this:
location week DV Predictor1 Predictor 2
location1 week1 xxx xxxxxxx xxxxxxxxx
location1 week2 xxx xxxxxxx xxxxxxxxx
.
.
.
location2 week1 xxx xxxxxxx xxxxxxxxx
location2 week2 xxx xxxxxxx xxxxxxxxx
My DV variable was mean-centered - for each location and I am using
this mean-centered DV as the DV in lm. Also, I am using the mean of
each location as a weight when I run this regression.
Would it still be correct to calculate pcse for this regression? I am
not sure because pcse uses the group identifier - so am I not somehow
double-counting things?
Thank you very much!
--
Dimitri Liakhovitski
Ninah Consulting
www.ninah.com
More information about the R-help
mailing list