Dear All
Is there a way where we can generate a new variable from an existing numeric variable with labels to take only the labels of the variable and not the values. When we write the following command :
"gen var=var2" and if var2 is a numeric variable with label then the new variable "var" will be a numeric variable taking only the values and not the label. I want it to take only the labels and not the value which means I want to generate a string variable taking the label of the existing variable "Var2".
Thank you in advance
Related Posts with How to generate a new variable that takes only the variable name of the other variable and not the value label
Tabulation/Descriptive StatisticsGreetings Everyone! Hopefully, you will be doing well. I have variable gender diversity in number. …
regressing group observations identified by id in loop and for each regression create a table outputHello. I am trying to create some doc/docx regression table output for each group of observations th…
Export Excel command questionGood afternoon, Is it possible to export part of a sheet only in the Stata data editor to Excel. Fo…
Compare levelsof to original var in if conditionI am looping over a variable, running a regression, and extracting the coefficient for each level (t…
Two way fixed effects and marginal effectsHello everyone, My model is Income inequality i,t = β0 +β1NatResit +β2 NatResi,tDemi,t+βn Xi,t + λt …
Subscribe to:
Post Comments (Atom)
0 Response to How to generate a new variable that takes only the variable name of the other variable and not the value label
Post a Comment