In this case, SAS programming will be performed. Below is the SAS Code to understand the frequency data:
DATA new; set mydata.addhealth_pds;
LABEL H1SU1="Seriously think about committing suicide during the past 12 months"
H1SU2="Attempt suicide during the past 12 months"
H1SU3="Any attempt result in an injury, poisoning, or overdose that had to be treated by a doctor or nurse"
H1SU8="How honestly have you answered the questions?";
/*Seriously thinking about comitting suicide*/
IF H1SU1=1;
/*Somewhat Honest to Completly Honest */
IF H1SU8 >= 2 and H1SU8 <=4 ;
PROC SORT; by AID;
PROC FREQ; TABLES H1SU1 H1SU2 H1SU3 H1SU8;
RUN;
The data is filtered by taking only young adult who seriously thinking about committing suicide during the past 12 months and who honestly answered the question (variable H1SU8 with code 2,3 and4). To know the meaning of the code each variables please refer to Adolescent Suicide Attempt Analysis in United States (Part 1).
Below is the frequency diagram for each variables:
As represented in the table, H1SU1 only has data with code 1 which the answer is 'Yes'. It can be seen that in total 794 adolescent who think to suicide, there are 220 adolescent (sum of code 1,2,3 and 4 of variable H1SU2) who attempt suicide or about 27.7 percent. The other 574 adolescent did not do the suicide. Furthermore, there are 60 adolescent or 7.56 percent (Variable H1SU3) who treated by doctor because of their suicide attempt. Based on the result, there is no missing data.
No comments:
Post a Comment