/***/ /* This SAS program reads ASCII format (text format) 1997 YRBS data and creates a */ /* formatted and labeled SAS dataset. */ /* */ /* Change the file location specifications from "c:\yrbs1997" to the location where */ /* you have stored the YRBS ASCII data file and the format library before you run this */ /* program. Change the location specification in three places - in the "filename" */ /* statement and in the two "libname" statements at the top of the program. */ /* */ /* Note: Run "YRBS_1997_SAS_Format_Program.sas" BEFORE you run */ /* "YRBS_1997_SAS_Input_Program.sas" to create the 1997 YRBS dataset. */ /***/ filename datain 'c:\yrbs1997\yrbs1997.dat'; libname dataout 'c:\yrbs1997'; libname library 'c:\yrbs1997'; data dataout.yrbs1997 ; infile datain lrecl=130; input Q1 $ 1-1 Q2 $ 2-2 Q3 $ 3-3 Q4 $ 4-4 Q5 $ 5-5 Q6 $ 6-6 Q7 $ 7-7 Q8 $ 8-8 Q9 $ 9-9 Q10 $ 10-10 Q11 $ 11-11 Q12 $ 12-12 Q13 $ 13-13 Q14 $ 14-14 Q15 $ 15-15 Q16 $ 16-16 Q17 $ 17-17 Q18 $ 18-18 Q19 $ 19-19 Q20 $ 20-20 Q21 $ 21-21 Q22 $ 22-22 Q23 $ 23-23 Q24 $ 24-24 Q25 $ 25-25 Q26 $ 26-26 Q27 $ 27-27 Q28 $ 28-28 Q29 $ 29-29 Q30 $ 30-30 Q31 $ 31-31 Q32 $ 32-32 Q33 $ 33-33 Q34 $ 34-34 Q35 $ 35-35 Q36 $ 36-36 Q37 $ 37-37 Q38 $ 38-38 Q39 $ 39-39 Q40 $ 40-40 Q41 $ 41-41 Q42 $ 42-42 Q43 $ 43-43 Q44 $ 44-44 Q45 $ 45-45 Q46 $ 46-46 Q47 $ 47-47 Q48 $ 48-48 Q49 $ 49-49 Q50 $ 50-50 Q51 $ 51-51 Q52 $ 52-52 Q53 $ 53-53 Q54 $ 54-54 Q55 $ 55-55 Q56 $ 56-56 Q57 $ 57-57 Q58 $ 58-58 Q59 $ 59-59 Q60 $ 60-60 Q61 $ 61-61 Q62 $ 62-62 Q63 $ 63-63 Q64 $ 64-64 Q65 $ 65-65 Q66 $ 66-66 Q67 $ 67-67 Q68 $ 68-68 Q69 $ 69-69 Q70 $ 70-70 Q71 $ 71-71 Q72 $ 72-72 Q73 $ 73-73 Q74 $ 74-74 Q75 $ 75-75 Q76 $ 76-76 Q77 $ 77-77 Q78 $ 78-78 Q79 $ 79-79 Q80 $ 80-80 Q81 $ 81-81 Q82 $ 82-82 Q83 $ 83-83 Q84 $ 84-84 Q85 $ 85-85 Q86 $ 86-86 Q87 $ 87-87 Q88 $ 88-88 Q89 $ 89-89 @90 WEIGHT 12.4 @102 PSU 5.0 @107 STRATUM 3.0 METROST $ 110-110 ; * * Assign formats to SAS variables.* *; format Q1 $Q1H. Q2 $Q2H. Q3 $Q3H. Q4 $Q4H. Q5 $Q5H. Q6 $Q6H. Q7 $Q7H. Q8 $Q8H. Q9 $Q9H. Q10 $Q10H. Q11 $Q11H. Q12 $Q12H. Q13 $Q13H. Q14 $Q14H. Q15 $Q15H. Q16 $Q16H. Q17 $Q17H. Q18 $Q18H. Q19 $Q19H. Q20 $Q20H. Q21 $Q21H. Q22 $Q22H. Q23 $Q23H. Q24 $Q24H. Q25 $Q25H. Q26 $Q26H. Q27 $Q27H. Q28 $Q28H. Q29 $Q29H. Q30 $Q30H. Q31 $Q31H. Q32 $Q32H. Q33 $Q33H. Q34 $Q34H. Q35 $Q35H. Q36 $Q36H. Q37 $Q37H. Q38 $Q38H. Q39 $Q39H. Q40 $Q40H. Q41 $Q41H. Q42 $Q42H. Q43 $Q43H. Q44 $Q44H. Q45 $Q45H. Q46 $Q46H. Q47 $Q47H. Q48 $Q48H. Q49 $Q49H. Q50 $Q50H. Q51 $Q51H. Q52 $Q52H. Q53 $Q53H. Q54 $Q54H. Q55 $Q55H. Q56 $Q56H. Q57 $Q57H. Q58 $Q58H. Q59 $Q59H. Q60 $Q60H. Q61 $Q61H. Q62 $Q62H. Q63 $Q63H. Q64 $Q64H. Q65 $Q65H. Q66 $Q66H. Q67 $Q67H. Q68 $Q68H. Q69 $Q69H. Q70 $Q70H. Q71 $Q71H. Q72 $Q72H. Q73 $Q73H. Q74 $Q74H. Q75 $Q75H. Q76 $Q76H. Q77 $Q77H. Q78 $Q78H. Q79 $Q79H. Q80 $Q80H. Q81 $Q81H. Q82 $Q82H. Q83 $Q83H. Q84 $Q84H. Q85 $Q85XXH. Q86 $Q86XXH. Q87 $Q87XXH. Q88 $Q88XXH. Q89 $Q89XXH. METROST $METROH.; * Assign labels to SAS variables.* ; label Q1="HOW OLD ARE YOU" Q2="WHAT IS YOUR SEX" Q3="IN WHAT GRADE ARE YOU" Q4="HOW DO YOU DESCRIBE YOURSELF" Q5="HOW OFTEN WEAR SEAT BELT WITH SOMEONE" Q6="HOW MANY TIMES RIDE MOTORCYCLE" Q7="HOW OFTEN WEAR HELMET RIDING MOTORCYCLE" Q8="HOW OFTEN RIDE BICYCLE" Q9="HOW OFTEN WEAR HELMET RIDING BICYCLE" Q10="HOW OFTEN RIDE WITH DRINKING DRIVER" Q11="HOW MANY TIMES DRIVE WHILE DRINKING" Q12="HOW MANY DAYS IN PAST 30 CARRY WEAPON" Q13="HOW MANY DAYS IN PAST 30 CARRY GUN" Q14="HOW MANY DAYS CARRY WEAPON AT SCHOOL" Q15="HOW MANY DAYS NO SCHOOL BECAUSE UNSAFE" Q16="HOW MANY TIMES THREATENED/INJURED SCHOOL" Q17="HOW MANY TIMES PROPERTY STOLEN AT SCHOOL" Q18="HOW MANY TIMES IN PHYSICAL FIGHT" Q19="HOW MANY TIMES INJURED IN FIGHT" Q20="HOW MANY TIMES IN FIGHT AT SCHOOL" Q21="WHOM WAS LAST FIGHT WITH" Q22="HAVE YOU SERIOUSLY CONSIDERED SUICIDE" Q23="DID YOU MAKE A PLAN ABOUT SUICIDE" Q24="HOW MANY TIMES DID ATTEMPT SUICIDE" Q25="DID SUICIDE ATTEMPT RESULT IN INJURY" Q26="HAVE YOU EVER TRIED CIGARETTE SMOKING" Q27="AGE WHEN SMOKED FIRST CIGARETTE" Q28="HOW MANY DAYS DID YOU SMOKE CIGARETTES" Q29="HOW MANY CIGARETTES PER DAY" Q30="HOW DID YOU GET YOUR CIGARETTES" Q31="ASKED FOR PROOF OF AGE BUYING CIGARETTES" Q32="HOW MANY DAYS SMOKE CIGARETTES AT SCHOOL" Q33="HAVE YOU TRIED TO QUIT SMOKING" Q34="DID YOU USE CHEWING TOBACCO OR SNUFF" Q35="USE CHEWING TOBACCO/SNUFF AT SCHOOL" Q36="AGE OF FIRST DRINK OF ALCOHOL" Q37="HOW MANY DAYS IN LIFE AT LEAST ONE DRINK" Q38="HOW MANY PAST 30 DAYS AT LEAST ONE DRINK" Q39="HOW MANY PAST 30 DAYS 5 OR MORE DRINKS" Q40="HOW MANY DAYS DRINK ALCOHOL AT SCHOOL" Q41="HOW OLD WHEN FIRST TRIED MARIJUANA" Q42="HOW MANY TIMES IN LIFE USED MARIJUANA" Q43="HOW MANY TIMES PAST 30 DAYS MARIJUANA" Q44="HOW MANY TIMES USE MARIJUANA AT SCHOOL" Q45="HOW OLD WHEN FIRST TRIED COCAINE" Q46="HOW MANY TIMES IN LIFE USED COCAINE" Q47="HOW MANY TIMES PAST 30 DAYS USE COCAINE" Q48="HOW MANY TIMES IN LIFE CRACK/FREEBASE" Q49="HOW MANY TIMES HAVE YOU SNIFFED GLUE" Q50="HOW MANY TIMES IN LIFE USED STEROIDS" Q51="HOW MANY TIMES IN LIFE USE ILLEGAL DRUGS" Q52="HOW MANY TIMES INJECTED ILLEGAL DRUG" Q53="ANYONE OFFERED YOU DRUGS AT SCHOOL" Q54="EVER TAUGHT ABOUT AIDS/HIV IN SCHOOL" Q55="EVER TALKED ABOUT AIDS WITH PARENTS" Q56="EVER HAD SEXUAL INTERCOURSE" Q57="AGE WHEN FIRST HAD SEXUAL INTERCOURSE" Q58="NUMBER OF SEX PARTNERS IN LIFE" Q59="NUMBER OF SEX PARTNERS IN PAST 3 MONTHS" Q60="USE ALCOHOL OR DRUGS BEFORE LAST SEX" Q61="USE CONDOM DURING LAST SEX" Q62="WHAT BIRTH CONTROL USED DURING LAST SEX" Q63="HOW MANY BEEN/GOTTEN SOMEONE PREGNANT" Q64="HOW DO YOU DESCRIBE YOUR WEIGHT" Q65="WHICH ARE YOU TRYING TO DO ABOUT WEIGHT" Q66="DID YOU DIET TO LOSE WEIGHT" Q67="DID YOU EXERCISE TO LOSE WEIGHT" Q68="DID YOU VOMIT TO LOSE WEIGHT" Q69="DID YOU TAKE DIET PILLS TO LOSE WEIGHT" Q70="HOW MANY TIMES DID YOU EAT FRUIT" Q71="HOW MANY TIMES DID YOU DRINK FRUIT JUICE" Q72="HOW MANY TIMES DID YOU EAT GREEN SALAD" Q73="HOW MANY TIMES EAT COOKED VEGETABLES" Q74="HOW MANY TIMES DID YOU EAT HAMBURGER" Q75="HOW MANY TIMES DID YOU EAT FRENCH FRIES" Q76="HOW MANY TIMES DID YOU EAT COOKIES" Q77="HOW MANY PAST 7 DAYS DO HARD EXERCISE" Q78="HOW MANY PAST 7 DAYS DO STRETCHING" Q79="HOW MANY PAST 7 DAYS DO TONING EXERCISE" Q80="HOW MANY DAYS BIKE/WALK FOR 30 MINUTES" Q81="HOW MANY DAYS DO YOU GO TO PE CLASS" Q82="HOW MANY MINUTES EXERCISE IN PE CLASS" Q83="ON HOW MANY TEAMS AT SCHOOL" Q84="ON HOW MANY TEAMS OUTSIDE SCHOOL" Q85="EVER SMOKED REGULARLY" Q86="DAYS SMOKED CIGARS LAST 30 DAYS" Q87="AGE OF PARTNER AT LAST SEX" Q88="HOW MUCH EDUCATION DOES MOTHER HAVE" Q89="HOW MUCH EDUCATION DOES FATHER HAVE" weight="Analysis weight" stratum="Stratum" psu="PSU" METROST="Metropolitan Status" ; run;