fork download
  1.  
  2. # testing data
  3. # list中每個element都是一個data frame
  4. # 表示不同方案的差異
  5.  
  6. list(structure(list(n = c(1, 2, 3, 4, 5, 6), count = c(16L, 77L,
  7. 159L, 152L, 73L, 23L), avg = c(9.1725, 10.2198051948052, 9.12234800838574,
  8. 9.40023026315789, 9.84950684931507, 10.161231884058)), class = c("tbl_df",
  9. "tbl", "data.frame"), row.names = c(NA, -6L), .Names = c("n",
  10. "count", "avg")), structure(list(n = c(1, 2, 3, 4, 5, 6), count = c(16L,
  11. 93L, 141L, 160L, 78L, 12L), avg = c(8.848125, 9.06784946236559,
  12. 8.89146572104019, 9.39596875, 9.04123076923077, 7.22930555555556
  13. )), class = c("tbl_df", "tbl", "data.frame"), row.names = c(NA,
  14. -6L), .Names = c("n", "count", "avg")), structure(list(n = c(1,
  15. 2, 3, 4, 5, 6, 7), count = c(14L, 80L, 165L, 153L, 75L, 12L,
  16. 1L), avg = c(9.69142857142857, 10.8685625, 10.800202020202, 11.0716013071895,
  17. 10.80032, 10.7166666666667, 11.2257142857143)), class = c("tbl_df",
  18. "tbl", "data.frame"), row.names = c(NA, -7L), .Names = c("n",
  19. "count", "avg")), structure(list(n = c(1, 2, 3, 4, 5, 6, 7),
  20. count = c(12L, 85L, 171L, 136L, 72L, 22L, 2L), avg = c(6.63916666666667,
  21. 7.97017647058824, 8.25945419103314, 8.49849264705882, 8.55227777777778,
  22. 8.73143939393939, 6.78071428571429)), class = c("tbl_df",
  23. "tbl", "data.frame"), row.names = c(NA, -7L), .Names = c("n",
  24. "count", "avg")), structure(list(n = c(1, 2, 3, 4, 5, 6, 7),
  25. count = c(11L, 75L, 137L, 190L, 75L, 11L, 1L), avg = c(8.84090909090909,
  26. 9.1746, 8.65717761557178, 9.96431578947368, 9.80224, 11.0812121212121,
  27. 8.44571428571428)), class = c("tbl_df", "tbl", "data.frame"
  28. ), row.names = c(NA, -7L), .Names = c("n", "count", "avg")))
Success #stdin #stdout 0.22s 176448KB
stdin
Standard input is empty
stdout
[[1]]
  n count       avg
1 1    16  9.172500
2 2    77 10.219805
3 3   159  9.122348
4 4   152  9.400230
5 5    73  9.849507
6 6    23 10.161232

[[2]]
  n count      avg
1 1    16 8.848125
2 2    93 9.067849
3 3   141 8.891466
4 4   160 9.395969
5 5    78 9.041231
6 6    12 7.229306

[[3]]
  n count       avg
1 1    14  9.691429
2 2    80 10.868562
3 3   165 10.800202
4 4   153 11.071601
5 5    75 10.800320
6 6    12 10.716667
7 7     1 11.225714

[[4]]
  n count      avg
1 1    12 6.639167
2 2    85 7.970176
3 3   171 8.259454
4 4   136 8.498493
5 5    72 8.552278
6 6    22 8.731439
7 7     2 6.780714

[[5]]
  n count       avg
1 1    11  8.840909
2 2    75  9.174600
3 3   137  8.657178
4 4   190  9.964316
5 5    75  9.802240
6 6    11 11.081212
7 7     1  8.445714