Hello All,
I have a panel dataset with 28 years and several U.S. states. Currently, I am trying to create a new 'United States' observation which is the yearly average of other states. I am doing this by first collapsing my data and then appending it to my original dataset. However, I am getting a really weird issue where my collapse command is 'working' but nothing is happening. This is the command I am using:
collapse Cigarette_Cap , by(Year GeoName)
I have no clue what the issue here is ... anyone have any ideas?
EDIT: If I can add, my data collapses when I do by(GeoName) or by(Year) but not when I do both. Is there an issue with how I am defining my varlist?
Thanks,
Mitchell
Related Posts with Problem Collapsing Data
No support for meqrlogit as of Stata 16I looked at the help file for meqrlogit in Stata 16 and it is no longer part of Stata 16. I couldn't…
Creating episodesDear All, I have an individual level panel data with 108 monthly waves. Code: Code: * Example …
marginsI have the following dataset. The dataset is about loans and it's interest rates, there are more var…
Variable Name Error (r198) in asregHi, I am trying to estimate the impact of directors' remuneration on firm performance. My unbalance…
Logistic Regression IssuesI am trying to perform a logistic regression but I am running into issues with the var. I keep getti…
Subscribe to:
Post Comments (Atom)
0 Response to Problem Collapsing Data
Post a Comment