Hi Everyone,
I am trying to set my data as a panel by using xtset command. I have uasid as identifier and year variables. When I use uasid, since it is a string variable my command doesn't work.
I did encode uasid to id to make sure I destring uasid. when I did that, I had the following problem on the attachement. After encoding, uasid and id do not match each other for each observations. How can I solve this problem?
Related Posts with Xtset and string variables
ivreghdfe interaction term!Hello, I'm using ivreghdfe and need to interact my instrument with a categorical variable. Could so…
Several updates and new packages on SSC (heatplot, colrspace, palettes, robstat, robbox)I made several additions and updates to packages on SSC over the last months about which I never inf…
Is there a Mata function for inputting to and outputting from local macros in the calling segment?Fellow Statalisters (especially StataCorp): Are there any Mata functions to input values from, and …
Diff-in-Diff Regression for Minimum Wage ImpactsHi all, I'm very new to Stata and I'm doing my own research for a class to write a paper. I'm trying…
Drop observations corresponding to other variableI have two variables, Names1 and Names2, both consisting of certain names. A simplified e.g. is past…
Subscribe to:
Post Comments (Atom)
0 Response to Xtset and string variables
Post a Comment