Split DateTime column into separate Date and Time Columns

or a more fancy way - just to practice the DataFrames.jl minilanguage :smile: (though I prefer the solution by @zweiglimmergneis as it is easier to understand)

transform!(F, @. :DateTime => ByRow([Date, Time]) => [:Date, :Time])

For completeness let me mention that one could also write:

transform!(F, :DateTime => ByRow(x -> (Date=Date(x), Time=Time(x))) => AsTable)
5 Likes