By default, the background
of all text is transparent. To specify a background color, you must
specify OPAQUE=TRUE to turn off transparency, which then enables you
to specify a background color. In the following example, the fill
color of the band is specified for the background of the entry text.
A border is also added.
Note: Data points that are behind
the entry text are obscured when OPAQUE=TRUE.
begingraph;
entrytitle "Regression Plot";
entryfootnote halign=right
"Prepared with SAS" {unicode "00AE"x} " Software" /
textattrs=(size=9pt);
layout overlay;
modelband "clm";
scatterplot x=height y=weight;
regressionplot x=height y=weight / clm="clm" alpha=.05;
entry {unicode alpha} " = .05" / autoalign=auto border=true
opaque=true backgroundcolor=GraphConfidence:color ;
endlayout;
endgraph;
Notice that extra space appears between the entry border
and the text. This space is called padding and can be set with the
PAD= option. The default padding is
ENTRY "string" / PAD=(LEFT=3px RIGHT=3px TOP=0 BOTTOM=0) border=true;
You can set the padding
individually for the LEFT, RIGHT, TOP, and BOTTOM directions, or you
can set the same padding in all directions as follows:
ENTRY "string" / PAD=5px border=true;
Padding is especially
useful when you want to add extra space between titles, or add space
between the last title (or first footnote) and the plot area in the
graph:
begingraph;
entrytitle "Regression Plot" / pad=(bottom=10px) ;
entryfootnote halign=right
"Prepared with SAS" {unicode "00AE"x} " Software" /
textattrs=(size=9pt) pad=(top=10px) ;
layout overlay;
modelband "clm";
scatterplot x=height y=weight;
regressionplot x=height y=weight / clm="clm" alpha=.05;
endlayout;
endgraph;