Is there a command to split a categorical variable into binary variables? For example, splitting a "race" variable with values "white, black, hispanic" to three variables: race1, race2, race3 where race1 = 1 if race = "white" etc.
Just wondering if someone created a command like this since it would save a lot of time!
Related Posts with Is there a command for quickly splitting a categorical variable into multiple binary variables?
a variable that indicates whether it is the first week of the month, second week, etc...Dear all, I have a date variable in my dataset in the following format: 27feb2015 20feb2015 13feb2…
Merge multiple csv filesDear all, I have a set of csv files named firm1, firm2, ..., firmn. Each file contains a specific d…
"Random Effect model and FGLS" "Fixed effect model and FGLS"Hi Experts Hope you are doing well! Details of my dataset: Unbalanced Panel Dataset Data were tak…
Calculating the sample size needed for population proportion estimationDear users, I am new to Stata, and my question is: what is the correct procedure for calculating the…
What are the stata commands for Poisson pseudo-maximum likelihood (PPML) in gravity model?Hey, I am estimating the gravity model to obtain residuals at the sectoral level. My goal is to calc…
Subscribe to:
Post Comments (Atom)
0 Response to Is there a command for quickly splitting a categorical variable into multiple binary variables?
Post a Comment