Keeping or deleting a group of observations based on a characteristic of a BY-group
问题 I answered a SAS question a few minutes ago and realized there is a generalization that might be more useful than that one (here). I didn't see this question already in StackOverflow. The general question is: How can you process and keep an entire BY-group based on some characteristic of the BY-group that you might not know until you have looked at all the observations in the group? Using input data similar to that from the earlier question: * For some reason, we are tasked with keeping only