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
Average of sales of x's which have average K/R ratioDear All, I am trying to calculate the average value of sales of firms which have their Capital/Rev…
Can we apply mswitch command when the time series data is stores in a panel format? Hi... Hello, I use Stata 15. I have a panel dataset. I want to estimate for each id/country. The…
AIC and BIC what is a low value ?A reviewer of my paper ask me the following question . The paper is about a model to predict complic…
Balanced vs. Unbalanced Panel Data for pooled time series cross sectionDear Stata Community, I need to decide whether I want to use an unbalanced or a balanced panel data…
inputting intraday data from bloombergHello, I have been trying to transform intraday data (downloaded from Bloomberg into an excel file)…
Subscribe to:
Post Comments (Atom)
0 Response to Combine two variables into a dummy variable
Post a Comment