|
I'm trying to devise a way to signal that a cell has the minimum value
for that column. The code below does not work and the error it gives in
the log is not helping me understand why it's not working.
I did have the COMPUTE block coded like so:
If _c4_ = aicmin then ....
But this didn't change the cell style of the minimal value in the
column, though it did not give an error message. I realize that AICMIN
and BICMIN are the minimal values PER row and not over the column.
Also, the COMPUTE block was COMPUTE AIC; but I received the same error
message.
Any suggestions??? Thanks much.
PROC REPORT DATA=WORK.OUTG2 SPLIT="/" HEADLINE HEADSKIP CENTER ;
COLUMN (modelx aic bic aic=aicmin bic=bicmin );
DEFINE modelx / DISPLAY FORMAT= $MODEL30. WIDTH=30 SPACING=2 FLOW
CENTER "Model/Tested" ;
DEFINE aic / DISPLAY FORMAT= COMMA8.2 WIDTH=8 SPACING=2 CENTER
"Akaike/Information/Criterion" ;
DEFINE bic / DISPLAY FORMAT= COMMA8.2 WIDTH=8 SPACING=2 CENTER
"Bayesian/Information/Criterion" ;
DEFINE aicmin / MIN FORMAT= COMMA8.4 WIDTH=8 SPACING=2 NOPRINT
RIGHT "aic" ;
DEFINE bicmin / MIN FORMAT= COMMA8.4 WIDTH=8 SPACING=2 NOPRINT
RIGHT "bic" ;
RBREAK AFTER / ;
COMPUTE AFTER ;
if _c4_ = aic.min then call define(_col_, "style",
"style=[background=cx808080 foreground=cxFFFF00 font_weight=bold]");
if _c5_ = bic.min then call define(_col_, "style",
"style=[background=cx808080 foreground=cxFFFF00 font_weight=bold]");
ENDCOMP;
RUN;
ERROR: The variable type of AIC.MIN is invalid in this context.
ERROR: The variable type of BIC.MIN is invalid in this context.
NOTE: The preceding messages refer to the COMPUTE block for RBREAK AFTER
.
NOTE: Will not run due to compilation errors.
NOTE: The SAS System stopped processing this step because of errors.
NOTE: There were 8 observations read from the data set WORK.OUTG2.
NOTE: PROCEDURE REPORT used:
real time 0.37 seconds
cpu time 0.04 seconds
John Gerstle
CDC Information Technological Support Contract (CITS)
Biostatistician
|