I currently have a variable called "Residence" which takes on two values: Urban and Rural
I'm generating a new variable called "Rural" which will take on values 1 for rural and 0 for urban. I'm creating this new variable based on this variable "Residence".
With the gen command, I'm facing problems of "type mismatch"
What should I do?
Related Posts with Generating a numeric variable from string variable
How do I generate a risk score and then use it to calculate quartile odds ratioHello I was looking for some assistance in generating a prediction risk score for a binary outcome …
error message returned when installing spost13 using Stata 17Hello, I would like to use Brant test for my ordered logistic regression models and tried to instal…
How to rewrite graph-like command that written by users under Stata 6.0 or earlierDear Stata users, Stata had changed its graph command since version 7. However there are a lot of c…
From single event observations to time seriesHi everyone, As I am quite new to Stata hope you can help me out with the next question. Currently…
Substracting different rows in StataHi all! I need your help, please! I have data from 2014q1 to 2019q4, what I want to do is subtract …
Subscribe to:
Post Comments (Atom)
0 Response to Generating a numeric variable from string variable
Post a Comment