Hey dear STATA Users,
I am meant to create a dummy variable.
That's literally a set of dummy variables that are based on a combination of "industry" and "occupation". For example, let's assume two industries (education, financial sector) and two occupations (manager, secretary). Then, you can have a four (two multiplied by two) dummy variables: (1) 1 if industry == education and occupation == manager or 0 otherwise; 1 if industry == education and occupation == secretary or 0 otherwise; and (3) and (4) similarly constructed.
But the combination of these two variables is really big.
I tried using egen job = group(occ ind), label but that takes too long.
Does anyone have any suggestions on what I should do?
Thank you!
Related Posts with Combine two variables into a dummy variable
Why can't SEM or GSEM produce fixed effects regressions?Hi all, I have been experimenting with structural equation modelling, and particularly GSEM in long…
Issues with Oaxaca DecompositionHi Community, I am currently doing a group project at university to analyse firm size effects on fe…
boottest with cmp and multiple equationsDear statalist members, I want to use boottest with cmp and mulitple equations, and I don't know ho…
How do I run a model with just coefficients from another datasetDear All, I am trying to validate a risk prediction model using logistic regression on a dataset. I …
Time dummies or Time trend?Hello everyone I have a question about time dummies and time trend, I hope someone can help. I have …
Subscribe to:
Post Comments (Atom)
0 Response to Combine two variables into a dummy variable
Post a Comment