I would like to extract ONLY the quarter from a date, e.g., to get an integer 1 from the date \"2003-02-08\". I have been trying something along this line
li
dint package also is suitable for that:
dint
library("dint") d=as.Date("2015-01-01") get_quarter(d)
you can find more about this package here.