可能重複:
R Grouping functions: sapply vs. lapply vs. apply. vs. tapply vs. by vs. aggregate vs如何應用功能跨越運行
我看起來像一個模型輸出文件:
run step x
1 1 1
1 2 4
1 3 3
1 1 4
1 2 5
1 3 6
2 1 5
2 2 4
2 3 7
2 1 3
。 。 。 我需要根據跑步數來計算每一步的平均值。我該如何做?非常感謝任何人,誰可以幫助我。 中提琴
我不熟悉的 「嘿」 的標籤。誰製造「嘿」,它用於什麼。有沒有開源的「嘿」實現? –
也dups:http://stackoverflow.com/questions/9593056/i-would-like-to-group-the-rows-of-this-dataset-by-index-and-then-sum-the-rows-通過/ 9593529 – thelatemail