This is a follow up question to Kikapp's answer.
I want to remove participant IDs which lack all the time-points. In other way around, I want to select rows which have all the four time (11, 21, 31, 41). See the sample data dropbox link
Here is my try based on Kikapp's answer. For some reason, it doesn't work. Let me know how to make it better.
data2 <- df[df$ID %in% names(table(df$ID))[table(df$ID) > 3],]
I get 4695 rows or objects or IDs for time == 11
, time == 21
,time == 41
while 4693 for time == 31
; however, I want they should be equal.