I'm looking for code to classify participants with depression using more complicated diagnostic criteria than I've used before with STATA.
The scale is the 9-item PHQ 9. Each item (phq_1 through phq_9) has a value of 0 - 3.
I need to identify participants based on meeting the following criteria:
Major Depression: phq_1 or phq_2 of at least 2 AND at least five items phq_1 through phq_9 of at least 2. (But if phq_9 is 1 or higher, it counts towards the five items).
Other Depression: phq_1 or phq_2 of at least 2 AND two, three, or four items phq_1 - phq_9 of at least 2. (Again, if phq_9 is 1 or higher, it counts towards the two, three or four items).
I would really appreciate tips or code on how to express these criteria. I'm stuck at:
gen mds = .
replace mds = 1 if
Thank you for any suggestions.
Related Posts with code for classifying participants based on complex criteria on a 9-item scale
Eigenvectors in Stata (mata) vs. MatlabHi everyone, maybe this is a very silly question and I am overlooking something very, very obvious. …
What causes the following error: data not spset r(459);copy http://www.stata-press.com/data/r15/homicide1990.dta ., replace copy http://www.stata-press.com…
Testing significance of Swamy–Arora estimator of variance component?Dear Statalisters, if I run a regression of the following form: Code: xtreg y x, re sa Is there an…
Merge monthly to spell dataI have two datasets, in one I have an ID and a month. The second is spell data with ID, start_date, …
SSC Install Failure: "nothing to install"Dear Statalist I recently reinstalled STATA 17 (before I was using STATA 15). Now I am facing proble…
Subscribe to:
Post Comments (Atom)
0 Response to code for classifying participants based on complex criteria on a 9-item scale
Post a Comment