Hi all please i need help,
i have 2 variables,
1: alcscore”: a continuous score containing the respondent’s alcohol consumption
2:female”: 0 being male and 1 being female
My boss has asked me to do this and i have been on this for so long but cannot get it right:
create the outcome variable indicating whether the respondent had any alcohol abuse issue. The variable “alcscore” contains a score that contains the information about the person’s alcohol consumption. The standard for detecting any alcohol abuse issue is that female with a score equal or greater than 3 would be considered having abuse problem while male with a score equal or greater than 4 would be considered having abuse problem. Please create a dummy variable with 1 indicating that the respondent had alcohol abuse problem and 0 indicating that the respondent did not have alcohol abuse problem.
Please help
Related Posts with Generate new variables from existing ones
Setting version, seed, and sortseed not sufficient for reproducibility?The following code appears to produce different results depending on the Stata 16.1 edition I use. …
Options starting with "no" doesn't work, bug or feature?I am defining a program that has non-required options. When the option starts with "no", it doesn't …
Clogit vs Xtlogit with FE vs Logit with Dummy VariablesHi, I have an unbalanced panel data of stocks with N=20,000 and T=50 years. I have 50 industries. I…
Chow test statisticHi everyone! I tried doing a chow test using -test- and the following command: Code: . suest Brahmi…
MFX table logit commandHi all, I'm fairly new to Stata since I need it to write my bachelor thesis. However I'm stuck... I…
Subscribe to:
Post Comments (Atom)
0 Response to Generate new variables from existing ones
Post a Comment