I'm a new R user I'm more used to SAS.
I have a dataset so:
test| tester |obs1| obs2
test1|1 | Y |Y
test1|2 |Y |N
test2 |1 |Y |Y
test2 |2 | Y |Y
test3 |2 |N |N
I want to 1) only keep tests where both testers took a test and 2) transform the data so it looks like this:
test| obs1_tester1 | obs1_tester_2| obs2_tester1 | obs2_tester2
test1| Y | Y | Y | N
test2| Y | Y |Y |Y
test4.....
I know that in SAS I could make a variable that counted the number of times each test was taken then delete any observation where the maximum number of times the test was taken was less than 2. Then use the transpose function to easily transpose the data set.
I don't really understand how to do this in R. Can someone point me in the right direction?