Thanks, SO much,, Removing 'else' did not remove the coding problem. I think using 'packy' as the format might cause a problem because 'packy' is created earlier to differentiate smokers from non-smokers. see below... /* never smoker =0 and ever smoker =1, must be sure that all variables are calculated based off TOEV because reflects recoding*/ if tobev = 1 then pkyr1=0; if tobev = 2 then pkyr1=1; if tobev = 3 then pkyr1=1; This is used to add the current and former smokers cigarettes per day if pkyr1=1 then do; cigsum=sum(cpd, cpd_smkq); end; Here is where 'packy' is created earlier in the program summing cigarettes and years smoked. /*PACK YEARS VARIABLE– (cigs per day * yrs smoked) divided by 20 */ if pkyr1= 1 then packy=((cigsum * yrsum) / 20); else packy=0; So, is it OK to use 'packy' as the format? other suggestions? Thanks, Cary
... View more