I am a beginner user of SPSS (never used it before)
I am a second year medical student in Australia, and have begun a short research scholarship concerning medication use.
The dataset I have inherited has 206 subjects. It Gives their medications on admission and discharge from hospital.
The medications are arranged (in my view annoyingly) in columns from 1st medication to in some cases 25 medications.
The medication columns are separated in the spreadsheet by many columns of other data each time (such as medication code, brand name etc).
Some patients have only a few medication columns filled in. Others have many (depending on the amount of medications they were on).
The medications have been entered at random (as they were read off the chart).
My problem is: I need to do a prevalence of how many patients are on a given medication (out of the entire cohort), and the percentage this represents.
I would like to do this for each medication.
I would also like to Analyse to see how many patients have less than 4 medications, from 5-9 and greater than 10.
Any help greatly appreciated!
This topic has been locked.
2 replies Latest Post - 2012-11-20T13:55:17Z by SystemAdmin
Pinned topic medication prevalence help me please...
Answered question This question has been answered.
Unanswered question This question has not been answered yet.
Updated on 2012-11-20T13:55:17Z at 2012-11-20T13:55:17Z by SystemAdmin
Re: medication prevalence help me please...2012-11-20T12:50:19Z in response to SystemAdminYou can get help by placing your cursor on a procedure name and click <f1>.
e.g., to get the details for completing the RECODE, MULT RESPONSE procedures suggested below.
1)Create a list of the relevant variables so that you can cannibalize it with copy-and-paste.
click <utilities> <variables> to paste a list of those variables into a syntax window.
Put an asterisk before the first variable name break the list into a a few lines to make it easier to see them in the syntax window.
Put a period after the last variable name.
autorecode variables = [paste the list of variables here without the asterisk and period] /into [ new variable list] /group /print.
3)Examine the list of names in the output.
so that all of the spellings and brand/generic names have the save value.
e.g., "TYLENOL" "Tylenol" "tylanol" "Acetofetamine" "acetaphetamine" "parcetamol" all get the same value.
recode [ new variable list]...
compute n_of_meds= nvalid([ new variable list]).
MULT RESPONSE group medstaken 'all meds taken by pt' [ new variable list] /variables = gender n_of_meds ...
Re: medication prevalence help me please...2012-11-20T13:55:17Z in response to SystemAdminIf you have Custom Tables (CTABLES) you can just define a multiple response set consisting of all the medication columns and tabulate it. The multiple response sets can also be used in charting via the Chart Builder.
A little more advanced: if the particular columns have some unique pattern in their names, you can use an extension command (Utilities > Define Variable Macro) to create a shorthand symbol for just those variables and then use that in your analysis commands. That menu item requires the Python Essentials and the SPSSINC SELECT VARIABLES extension command. They can be downloaded from the SPSS Community site via the Downloads for SPSS Statistics page.