Hi everyone,

In my dataset I have business calender dates in the format %tbtrdates. I'm trying to extract the year of said dates, but I'm getting dates that are about 48 years off (not exactly 48 years off, i checked that). I'm not a regular user of Stata, so it might be a dumb question. I used the code:
generate year = year(date)
and
generate year = yofd(date)
but both yield the same faulty results.

is there a way to extract the year out of the business date cleanly?

Friendly regards,

Ron Dankers