Below this text is the first SAS program I have ever written. With this program I used I focused on the 6,138 individuals surveyed that had a total family income in last 12 months greater than $80,000 out of the total 43,093 surveyed for NESARC. I used this program to create three frequency tables based on the survey results for three questions about alcohol use.
The table "How Often Drank Any Alcohol in Last 12 Months" uses categorical variables to measure someone's drinking habits with the following code.
1.
Every day
2.
Nearly every day
3.
3 to 4 times a week
4.
2 times a week
5.
Once a week
6.
2 to 3 times a week
7.
Once a month
8.
7 to 11 times in the last
year
9.
3 to 6 times in the last
year
10. 1 or 2 times in the last year
99. Unknown
In all frequency tables, 99 means an unknown amount and missing frequencies mean non-applicable as the respondents are either non-drinkers or former drinkers.




No comments:
Post a Comment