我有这个数据框架:
Button,Intensity,Acc,Intensity,RT,Time
0,30,0,0,0,77987.931
1,30,1,13.5,0,78084.57
1,30,1,15,0,78098.624
我想添加一个列,它是两个时间计数之间的增量,例如:
Button,Intensity,Acc,Intensity,RT,Time, DELTA
0,30,0,0,0,77987.931, 0
1,30,1,13.5,0,78084.57, 96.639
1,30,1,15,0,78098.624, 14.054
我是R的新手,所以我不知道从哪里开始。谢谢!