Hi,
I am trying to create a categorical variable of "activity". I want 0=<150 mins of activity. and 1=>/equal to 150mins of activity.
I have two continuous variable categories:
Moderate for which each frequency = 15 mins (e.g. 4 = 60 mins)
Strenuous for which each frequency = 30 mins (e.g. 4 = 120 mins)
I want the categorical variable to be able to be = 1 for any combination of the continuous variables that is >/equal to 150 mins or =0 if <150 mins of activity.
Is anyone able to help by providing some advice as to the type of commands which would be suited to this?
Thank you
Ben
Related Posts with Creating categorical variables with multiple different conditions from continuous variables
Labeling observations in qnorm plotHello all I would like to add a label to the observations that isn't normally distributed in my qno…
Labeling values less than 1Hello, I would like to label values of less than 1 and am running into an error: "may not label .33…
Nearstat Error MessageDear Statalist-Community, I am trying to calculate the distance between two datsets using their lat…
Mean/median difference between quintiles significant and how to calculateHi, I want to calculate whether the difference between the mean (and median) of COGS elasticity of …
Connect VariablesHi everyone, hope you had a nice Christmas. I am having some Stata issues and i hope that someone …
Subscribe to:
Post Comments (Atom)
0 Response to Creating categorical variables with multiple different conditions from continuous variables
Post a Comment