Created
June 5, 2020 16:15
-
-
Save statgeek/6e24924247df53a872df1a9a2497e142 to your computer and use it in GitHub Desktop.
R - convert a month number to a month name
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
month <- c(12,3,6,2,3,7) | |
month.abb[month] | |
#[1] "Dec" "Mar" "Jun" "Feb" "Mar" "Jul" | |
#To apply as label in graphs: | |
factor(month.abb[serviceMonth], levels=month.abb) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment