Colleagues, Here is my dataset.
Serial Measurement Meas_test Serial_test 1 17 fail fail 1 16 pass fail 2 12 pass pass 2 8 pass pass 2 10 pass pass 3 19 fail fail 3 13 pass pass If a measurement is less than or equal to 16, then Meas_test is pass. Else Meas_test is fail This is easy to code. Serial_test is a pass, when all of the Meas_test are pass for a given serial. Else Serial_test is a fail. I'm at a loss to figure out how to do this in R. Some guidance would be appreciated. All the best, Thomas Subia ______________________________________________ R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.