******************************************************************** * File HALCyon cortisol syntax_HCS.do * BY Mike Gardner, University of Bristol * FOR HALCyon cross-cohort collaboration (funded by the New Dynamics of Ageing (RES-353-25-0001)) * DATASET Hertfordshire Cohort Study (HCS) * Date Created 26/03/2010 * last modified 02/08/2010 * PURPOSE Cleans and derives cortisol variables (at wave 1) ************************************************************************************* set more off sum cortisolnmoll, detail hist cortisolnmoll **Distribution isn't skewed and appears normal, hence no need to log normal transform **CORTISOL **Omit those on oral (fqdrgh10), nasal (fqdrgo1) and topical (fqdrgd1) corticosteroids sum cortisolnmoll replace cortisolnmoll=. if(fqdrgh10==1) replace cortisolnmoll=. if(fqdrgo1==1) replace cortisolnmoll=. if(fqdrgd1==1) sum cortisolnmoll **Blood samples were taken at wave 1 clinic 1999-2004 **rename cortisol, zscore and put into quartiles rename cortisolnmoll cortisol_w1c label variable cortisol_w1c "Cortisol at wave 1 clinic" zscore cortisol_w1c xtile cortquart=cortisol_w1c, nq(4) table cortquart, c(n cortisol_w1c min cortisol_w1c max cortisol_w1c) xtile cortbin=cortisol_w1c, nq(2) table cortbin, c(n cortisol_w1c min cortisol_w1c max cortisol_w1c)