Hi Everyone,
I have a dataset looking like this:
Date id var1 var2 var3 var4...
2010 1 ... ... ... ...
2010 1 ... ... ... ...
2010 1 ... ... ... ...
2010 2 ... ... ... ...
2010 2 ... ... ... ...
2010 2 ... ... ... ...
2010 3 ... ... ... ...
2010 3 ... ... ... ...
2010 3 ... ... ... ...
I'd like to find mean of each variable by id. That is, at the end, I want to achieve something like this:
Date id mean_var1 mean_var2 mean_var3 mean_var4...
2010 1 ... ... ... ...
2010 2 ... ... ... ...
2010 3 ... ... ... ...
It would be great if you can help. Thank you in advance.
Best,
Related Posts with Taking Average by id
Use of various Xtpcse options Dear statisticians, In my panel data (balanced, T<N) below tests are showing that there is heter…
Help producing line graphHi all, I have somewhat of embarrassing question. I am trying to make a line graph that displays wh…
Fixed effects and cluster error in gravity modelDear all. I need your help. I am working in a gravity model that pretends to estimate Colombian expo…
The Hausman test for endogeneityI have read in a paper that we can use Hausman test for endogeneity. and the authors mentioned that …
Using analytical weight in STATA's mixed effects modelI have a learning assessment dataset of over 60 countries and 2-5 years/waves. While countries are t…
Subscribe to:
Post Comments (Atom)
0 Response to Taking Average by id
Post a Comment