erikafille.ph
Add Multiple Columns to Pandas Dataframe from Function
If you have a pandas data frame mydf that has, for example, two columns mydate and mytime (both are of type datetime), to add three more columns: hour, weekday, and weeknum, one can write and execu…