Her is another R base
approach:
From your example: Some date:
Some_date<-"01/01/1979"
We tell R, "That is a Date"
Some_date<-as.Date(Some_date)
We extract the month:
months(Some_date)
output: [1] "January"
Finally, we can convert it to a numerical variable:
as.numeric(as.factor(months(Some_date)))
outpt: [1] 1