Added new example to change_agecomp function and fixed bug