In python I have a column name on Pandas:
Example
country/Region 1/22/19 1/23/19 1/24/19 1/25/19 1/26/19
how can I change date to weekday
country/Region Tue Wed Thu Fri Sat
*It have a lot of column than Example
In python I have a column name on Pandas:
Example
country/Region 1/22/19 1/23/19 1/24/19 1/25/19 1/26/19
how can I change date to weekday
country/Region Tue Wed Thu Fri Sat
*It have a lot of column than Example
Assuming all your columns are dates, use something like:
df.columns = [pd.to_datetime(col).day_name() for col in df.columns]