« first day (2462 days earlier)      last day (820 days later) » 

7:39 AM
Good morning all :)
 
8:04 AM
Hello
 
8:32 AM
Hello
DT experts: what is DT way of doing this? stackoverflow.com/q/70738138/680068
dcast(df, code + name ~ year, value.var = c("act_value", "pred_value")) would give year value at the end:
act_value_2019, act_value_2020, etc.
OP wants
2019_act_value 2020_act_value, etc.
 
8:59 AM
hello
 
 
4 hours later…
12:52 PM
@zx8754 only with post-processing you could change the columnnames into the exact format OP wants AFAIK
 
1:09 PM
@Jaap I checked the stats::reshape, the order is hardcoded, probably same for dt
 

« first day (2462 days earlier)      last day (820 days later) »