College of Education | University of Iowa

When you use a BY statement in your data step, SAS creates variables called ‘FIRST.’ and ‘LAST.’. These variables identify the first and last observation with each value of the variables on the BY statement. This is also great to use if you have multiple observations for people and you only want the first one or you only want the last one. ................
................