Reputation: 21
I am working on a clinical research project using a large dataset of nationwide hospital discharges. We are using SPSS for statistical analysis.
The dataset contains 25 diagnoses variables (DX1-DX25) which capture up to 25 diagnoses per discharge. A patient could have multiple diagnoses, so DX1 would be the primary diagnosis, DX2 is the secondary, etc.
The DXn variables are string variables that contain ICD-9 codes. ICD-9 is a system of diagnostic codes for classifying diseases.
We would like to know the 10 most common diagnoses (ICD-9 codes) across all 25 diagnoses variables. Is there a way to run a frequency analysis across all 25 diagnoses variables in SPSS? In other words, I would like one frequency table that shows the combined frequency/occurrence of each ICD-9 code.
Thanks!
Upvotes: 2
Views: 2350
Reputation: 5417
If you have access to the Custom Tables (CTABLES) procedure, you can define a multiple category set (Analyze > Tables > Multiple Response Sets and use the Custom Tables procedure to tabulate across all the variables in the set. This works whether the variables are string or numeric.
Upvotes: 2
Reputation: 11310
You could restructure (to get all the diagnoses in one variable) and then use a simple frequency analysis:
varstocases /make DX from DX1 to DX25.
freq DX.
You should do this in a separate dataset and keep your original dataset structure. For example:
dataset name OrigData.
dataset copy ForRestr.
dataset activate ForRestr.
varstocases .....
freq ....
dataset activate OrigData.
Upvotes: 1