Customizing the Kaplan-Meier Survival Plot

Dynamic Variables

Graph templates consist of instructions, written by SAS developers, in conjunction with SAS procedure code. However, SAS developers cannot fully provide some instructions when the template is written, because some elements of some graphs cannot be known until the procedure runs. For example, the legend title in a graph that has multiple strata corresponds to the label or name of the stratification variable, and the procedure calculates the p-value for the homogeneity test. SAS procedures create dynamic variables to provide some run-time information to graphs.[20] Some dynamic variables are set by the procedure and are declared in the template. Other dynamic variables are also set by the procedure, but you must declare them directly or through the template modification macros before you can use them.

[20] Axis labels can be set directly in the template or at run time through dynamic variables or through data object column labels.