Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

get month name from datetime pandas

#if you have a column whose format is datetime in your dataframe,
#and you want to extract the month name from it in a list
df['datetime_column'].dt.month_name()
#returns list of full month names (e.g. January, February)
Source by pandas.pydata.org #
 
PREVIOUS NEXT
Tagged: #month #datetime #pandas
ADD COMMENT
Topic
Name
4+1 =