I have a data frame like
date X1 X2 X3
4/16/2019 0:00 1 2 3
4/16/2019 7:00 1 2 3
4/172019 0:00 1 2 3
4/17/2019 7:00 1 2 3
I would like to get
date time X1 X2 X3
4/16/2019 c(0,7) c(1,1) c(2,2) c(3,3)
4/17/2019 c(0,7) c(1,1) c(2,2) c(3,3)
where X1 is a list and X1[[1]] is a vector, that is c(1,1).
Is there an efficient way to achieve this? Thank you!