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
Firthlogit with profile likelihood limits and p-valueI have read the forum post on generating profile log likelihood limits https://www.statalist.org/for…
How can I plot distinct color for different cluster results in a map setting?Hello everyone! I am doing the hierarchical clustering model in Stata on the county level. My resul…
Rangejoin Overlapping YearsHi all, Working with two different event datasets: event1 and event2. If the dates overlapped I wou…
Fixed effect for a monthI'm working with a panel data set (unbalanced) with year and month on it. I grouped by the household…
Spanning the columns of the each of two rows using esttabI would like to make the first table, Want This Result. What I have made so far is the second table,…
Subscribe to:
Post Comments (Atom)
0 Response to Creating categorical variables with multiple different conditions from continuous variables
Post a Comment