Hello all,
I am generating a scoring for a few parameters and I have the raw numbers to generate a scoring. I was the scoring to be in the same variable... Let me explain:
Ideally my new variable would be "Smoking Score" and a 0 is assigned to the values that are equal to 1 in my "smoken" variable. 1 is assigned to those who are "smokev == 1" AND "smoken == 0". Lastly, 2 would be assigned to those with "smoken == 0" and "smokev == 0"
So I am creating a variable that has scoring properties from TWO different variables. If you are an R user, is this easier in R? I hate moving my dataset back and forth and want to see if this is possible in STATA.
Related Posts with Making a new variable along parameters of other variables
Dominance analysis (domin) after xthybridDear all, I'm using the user-written command xthybrid (see Schunck & Perales, 2017, full refere…
Stacking a bar graphHi, I have a binary variable (childcare_nofsa) and a categorical variable (state). I'd like to prod…
Question about Rank AcrossGood morning, I have 3 variables that I need to rank. There are some cells in those variables that …
clustered standard errors in double selection lasso causes error (dslogit, vce(cluster clustervar))Dear Statalist-users, I´m using Stata 16.1. In my analysis I want to cluster standard errors at the…
how to use table command to analyze multiple choice question?hi masters, I just meet a problem which is somewhat frustrated. The survey question always contain…
Subscribe to:
Post Comments (Atom)
0 Response to Making a new variable along parameters of other variables
Post a Comment