Means of Transformed versus Untransformed Data Don't Match I am doing an ANOVA analysis, and to correct for normality, I used a log transformation on the response variable, RATING. I am trying to display some summary statistics. When I find the means of RATING and LOG_RATING, LOG_RATING is close to what I calculate the value to be, but not exactly the same. As in log(RATING) does not equal LOG_RATING. There is no missing data, so I am very confused.
Cohort is a categorical value 1 through 6. Rating is quantitative.
Here is the relevant code, output, and what log(RATING) should equal. Thoughts?
DATA SHEET1;  
SET SHEET1;  
LOG_RATING=LOG(RATING);  
RUN;

PROC SORT  DATA=SHEET1;  
BY COHORT;  
RUN;

PROC MEANS DATA=SHEET1 N MEAN VAR MAXDEC=2 ;  
CLASS COHORT;  
BY RATING;  
RUN;



(Expanding my comments into an answer.)
The first hint at the explanation is that your hand-computed values are always greater than what the program gave you.
The values are different because the order in which you took the log and the mean are different. The log of the mean is greater than (or equal to) the mean of the log (Jensen’s inequality). The operations don’t commute. Your “should” column is the former, and your program output is the latter.

(In the figure, we take the mean of two points for simplicity. The function f is the log function.)
