Hi, this is Alice.
I am constantly facing problems of destring a variable that contains both numerical and character context.
Question 1: How can I force the stata to import every variable in string not numeric?
Question 2 When importing variables that contain both numeric and text, I can only use encode. Destring will not work and gen var= real(var) will give me missing values
However, after encoding, the variable value was totally messed up by default.
How can I convert the string variable into numeric by its lab value?
Question 3 would be how can I filter variables by their lab value? as is " keep if var equal to " lable value"
I am sure there is an easy way, but my knowledge is very limited.
Please see attached screen shots for a better interpretation of my questions.
Thank you very much and looking forward your reply
0 Response to encode and destring
Post a Comment