Guest User

Untitled

a guest
Aug 19th, 2019
64
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. id <- rep(c(300,450), each=6)
  2. > visit <- rep(1:6,2)
  3. > trt <- rep(c(0,"A",0,"B",0,"C"),2)
  4. > q1 <- c(0,100,0,89,0, 60,0,85,0,40,0, 20)
  5. > df <- data.frame(id,visit,trt,q1)
  6. > df
  7. id visit trt q1
  8. 1 300 1 0 0
  9. 2 300 2 A 100
  10. 3 300 3 0 0
  11. 4 300 4 B 49
  12. 5 300 5 0 0
  13. 6 300 6 C 60
  14. 7 450 1 0 0
  15. 8 450 2 A 91
  16. 9 450 3 0 0
  17. 10 450 4 B 40
  18. 11 450 5 0 0
  19. 12 450 6 C 20
  20. >
RAW Paste Data