I am working with a panel of UK industries from 1997-2018, and wish to group some of these industries. I have already created an industry identifier variable using the command
encode industry, gen(ID)
Each industry is represented by a letter from A to S, and the industries I wish to group together are B,D,E,K,L
How exactly can I achieve this? Ideally I will generate a variable named something like highprodind which is equal to 1 for the aforementioned industries.
Thanks
Related Posts with Creating subgroups in panel data
About Foreach or ForvalueHi! I am trying to create seven summary variables named den_1 to den_7 to simplify the results I hav…
Help: weights not allowed r(101)Hi! I met a mistake in following command: egen x2 = group(sex re age educ) gen wm = sex == 1 &…
Estimating latent class models in Stata using both categorical and continuous indicator variablesHi Statalist community, I am trying to run latent class models and I am fairly new to this type of …
GLM binomial logit model gof - DevianceGood day, I'm using Stata 16 and trying to do gof for a glm logit model but the results show a lot …
Formatted IQR using CollectHi, I am using the excellent Example 3 in the "Stata Customizable Tables" manual to help me build a…
Subscribe to:
Post Comments (Atom)
0 Response to Creating subgroups in panel data
Post a Comment