我有3列的表,现在如何使用单个date_time转置数据
variables date_time value
gen_3 11-Jun-14 00:00:00 0.26
gen_3 11-Jun-14 00:00:01 0.59
gen_3 12-Aug-14 00:00:02 1.59
gen_3 12-Aug-14 00:00:04 3.59
gen_4 11-Jun-14 00:00:01 251.66
gen_4 11-Jun-14 00:00:02 156.42
gen_4 12-Aug-14 00:00:02 1198.42
gen_4 12-Aug-14 00:00:04 98.42
gen_3 12-Aug-14 00:00:03 Null(missing)
gen_4 12-Aug-14 00:00:03 Null(missing)
输出应该是
date_time gen_3 gen_4
11-Jun-14 00:00:00 0.26
11-Jun-14 00:00:01 0.59 251.66
11-Jun-14 00:00:02 156.42
12-Aug-14 00:00:02 1.59 1198.42
12-Aug-14 00:00:03
12-Aug-14 00:00:04 3.59 98.42
请求帮助,提前致谢。