We haven’t explained why variable Y is missing in observation 5 in the first example. The discussion explains why Y is 999 in observation 8 – because Y is not reset so the value of 999 in previous observations persists to the end. Wouldn’t that similarly suggest that the value of Y in observation 5 should be 999? I think I remember reading somewhere that the data step resets the PDV when starting to read any new dataset named in the SET statement. Is that true? (This rule gets complicated with the addition of BY group processing.) If that’s true, is that then the reason Y=. in observation 5?