Hello There are many approaches to solving your issue. I would prefer by creating formats and using them. With your case in mind, I would have the following code to create formats
proc format;
value **bleep**e low-45='LOW' 45-49=1 50-54=2 55-59=3 60-64=4 65-69=5 69-high='High';
value fincome Low - < 40000=0 40000 - high=1;
value $grad "N"=0 "Y"=1 Other="Missing";
run;
Points to note. If age is less then 45 or missing, you will get a "LOW". Similarly for age greater than 69 you will see high.
For income less than 40000 includes missing values. I have assumed that for college graduation your data has a response of 'Y' or 'N". Accordingly the values are set. If this value is missing you will "Missing".
You need to code based on your detailed logic and data.
For somebody new to SAS, I would recommend this training from SAS https://support.sas.com/edu/schedules.html?crs=PROG1&ctry=US . This gives a good understanding of SAS.
Having a copy of at least one of the books "The SAS Little SAS Book" or "SAS Programming By Example" is very helpful and saves time.
... View more