What factors affect how much money a doctor can make in retirement?