As a researcher, I get data with various data formatting- And it was always annoying to convert the dates because I would often forget the codes- So here I share the codes to convert various string dates to STATA format dates. Convert DD/MM/YYYY: gen numeric_date=date(string_date, “DMY”) Convert YYYY-MM-DD or YYYYMMDD: Continue Reading