How to: |
You can display missing data values (in a bar graph, line graph, area graph, or any variation of these graph types) in one of the following formats:
Note: You can specify a default value (other than the default value of zero) to represent missing data. To do this use a DEFINE command. For details, see Handling Records With Missing Field Values.
GRAPH FILE filename . . . SET VZERO={ON|OFF} ON GRAPH SET STYLE * *GRAPH_SCRIPT API call *END ENDSTYLE END
where:
Displays missing values as zero. An API call is not necessary when VZERO is set to ON. Alternatively, you can add ON GRAPH SET VZERO ON.
Displays missing values as a gap, a dotted line to zero, or, an interpolated dotted line, depending on the API call that is added. Alternatively, you can add ON GRAPH SET VZERO OFF.
Determines how missing values display in the graph when VZERO is set to OFF. Possible values are:
setFillMissingData(0); displays missing values as a gap.
setFillMissingData(1); displays missing values as a dotted line to zero.
setFillMissingData(2); displays missing values as an interpolated dotted line.
The following illustrates how missing values are represented in a bar graph when designated to appear as zero. The CURR_SAL value for Seay is missing, as well as the RAISE value for Bryant and Huntley.
SET LOOKGRAPH=BAR SET GRAPHEDIT=SERVER SET GRID=ON SET VZERO=ON GRAPH FILE MSFATIA SUM CUR_SAL RAISE ACROSS LAST_NAME ON GRAPH SET STYLE * *GRAPH_SCRIPT setTextRotation(getO1Label(),0); *END ENDSTYLE END
The output is:
The following illustrates how missing values are represented in a bar graph when designated to appear as a gap. The CURR_SAL value for Seay is missing, as well as the RAISE value for Bryant and Huntley.
SET LOOKGRAPH=BAR SET GRAPHEDIT=SERVER SET GRID=ON SET VZERO=OFF GRAPH FILE MSFATIA SUM CUR_SAL RAISE ACROSS LAST_NAME ON GRAPH SET STYLE * *GRAPH_SCRIPT setFillMissingData(0); setTextRotation(getO1Label(),0); *END ENDSTYLE END
The output is:
The following illustrates how missing values are represented in a line graph when designated to appear as a dotted line to zero. The CURR_SAL value for Seay is missing, as well as the RAISE value for Bryant and Huntley.
SET LOOKGRAPH=LINE SET GRAPHEDIT=SERVER SET GRID=ON SET VZERO=OFF GRAPH FILE MSFATIA SUM CUR_SAL RAISE ACROSS LAST_NAME ON GRAPH SET STYLE * *GRAPH_SCRIPT setFillMissingData(1); setTextRotation(getO1Label(),0); *END ENDSTYLE END
The output is:
The following illustrates how missing values are represented in a line graph when designated to appear as an interpolated dotted line. The CURR_SAL value for Seay is missing, as well as the RAISE value for Bryant and Huntley.
SET LOOKGRAPH=LINE SET GRAPHEDIT=SERVER SET GRID=ON SET VZERO=OFF GRAPH FILE MSFATIA SUM CUR_SAL RAISE ACROSS LAST_NAME ON GRAPH SET STYLE * *GRAPH_SCRIPT setFillMissingData(2); setTextRotation(getO1Label(),0); *END ENDSTYLE END
The output is: