Calculate age at a certain date with month and year variable (option 2)
This calculation uses separate year and month of birth variables to calculate the age of a subject at a date (in this example date of complication). The result is the age in years with 2 digits. Please take into account that this is not a precise age due to the missing day of birth. To only get the result in years, replace the ‘M’ with ‘y’ and remove /12.