Graph-Specific Tags Understanding the Graph Tags

24-8 Web User Interface Developers Guide for Oracle Application Development Framework Example 24–2 Sample Code for a Set of Alert Tags dvt:areaGraph id=areaGraph1 subType=AREA_VERT_ABS dvt:background dvt:specialEffects dvt:background dvt:graphPlotArea dvt:alertSet dvt:alert xValue=Boston yValue=3.50 yValueAssignment=Y1AXIS imageSource=myWarning.gif dvt:alert xValue=Boston yValue=5.50 yValueAssignment=Y1AXIS imageSource=myError.gif dvt:alertSet dvt:o1Axis dvt:y1Axis dvt:legendArea automaticPlacement=AP_NEVER dvt:areaGraph

24.3 Understanding Data Requirements for Graphs

Data requirements for graphs differ with graph type. Data requirements can be any of the following kinds: ■ Geometric: Some graph types need a certain number of data points in order to display data. For example, a line graph requires at least two groups of data because a line requires at least two points. ■ Complex: Some graph types require more than one data point for each marker which is the component that actually represents the data in a graph. A scatter graph, for example, needs two values for each group so that it can position the marker along the x-axis and along the y-axis. If the data that you provide to a graph does not have enough data points for each group, the graph component does its best to display a graph. ■ Logical: Some graph types cannot accept certain kinds of data. The following examples apply: – Negative data issues: Do not pass negative data to a pie graph or to a percentage bar, line, or area graph. Markers will not display for negative data in percentage graphs. – Null or zero data: You cannot see markers for null data because markers will not be produced for null data. Also, if a graph receives zero data and the axis line is at zero, the marker is not visible. However, if the axis line is at nonzero, the zero marker is visible. – Insufficient sets or series of data: Dual-Y graphs require a set of data for each y-axis. Usually, each set represents different information. For example, the y1-axis might represent sales for specific countries and time periods, while the y2-axis might represent total sales for all countries. If you pass only one set of y-axis data, then the graph cannot display data on two different Y-axes. It displays the data on a single y-axis. Similar graphs share similar data requirements. For example, you can group the following graphs under the category of area graphs: ■ Absolute area graph. ■ Stacked area graph. ■ Percentage area graph. Using ADF Graph Components 24-9

24.3.1 Area Graphs Data Requirements

An area graph is one in which data is represented as a filled-in area. The following kinds of area graphs are available: ■ Absolute: Each area marker connects a series of two or more data values. This kind of graph has the following variations: Absolute area graph with a single y-axis and absolute area graph with a split dual-Y axis. In a split dual-Y graph, the plot area is split into two sections, so that sets of data assigned to the different Y-axes appear in different parts of the plot area. ■ Stacked: Area markers are stacked. The values of each set of data are added to the values for previous sets. The size of the stack represents a cumulative total. This kind of graph has the following variations: Stacked area graph with a single y-axis and stacked area graph with a split dual y-axis. ■ Percentage: Area markers show the percentage of the cumulative total of all sets of data. Data guidelines for area graphs are: ■ Area graphs require at least two groups of data. A group is represented by a position along the horizontal axis that runs through all area markers. In a graph that shows data for a three-month period, the groups might be labeled Jan, Feb, and Mar. ■ Area graphs require one or more series of data. A filled-in area represents a series or set of data and is labeled by legend text, such as the continent of the Americas, Europe, and Asia. ■ Percentage area graphs cannot have negative numbers. ■ Dual-Y graphs require two sets of data.

24.3.2 Bar Graph Data Requirements

A bar graph is one in which data is represented as a series of bars. The following kinds of bar graphs are available: ■ Clustered: Each cluster of bars represents a group of data. For example, if data is grouped by employee, one cluster might consist of a Salary bar and a Commission bar for a given employee. This kind of graph includes the following variations: Vertical clustered bar graphs and horizontal clustered bar graphs. All variations of clustered bar graphs can be arranged as single y-axis, dual y-axis, and split dual y-axis graphs. ■ Stacked: Bars for each set of data are appended to previous sets of data. The size of the stack represents a cumulative data total. This kind of graph includes the following variations: Vertical stacked bar graphs and horizontal stacked bar graphs. All variations of stacked bar graphs can be arranged as single y-axis, dual y-axis, and split dual y-axis graphs. ■ Percentage: Bars are stacked and show the percentage of a given set of data relative to the cumulative total of all sets of data. Percentage bar graphs are arranged only with a single y-axis. Data guidelines for bar graphs are: ■ Percentage bar graphs cannot have negative numbers. ■ Dual-Y graphs require two sets of data. 24-10 Web User Interface Developers Guide for Oracle Application Development Framework

24.3.3 Bubble Graph Data Requirements

A bubble graph is one in which data is represented by the location and size of round data markers bubbles. Each data marker in a bubble graph represents three group values: ■ The first data value is the X value. It determines the marker’s location along the x-axis. ■ The second data value is the Y value. It determines the marker’s location along the y-axis. ■ The third data value is the z value. It determines the size of the marker. The following kinds of bubble graphs are available: Bubble graph with a single y-axis and bubble graph with a dual y-axis. Data guidelines for a bubble graph are: ■ Bubble graphs require at least three data values for a data marker. ■ For more than one group of data, bubble graphs require that data must be in multiples of three. For example, in a specific bubble graph, you might need three values for Paris, three for Tokyo, and so on. An example of these three values might be: X value is average life expectancy, Y value is average income, and z value is population.

24.3.4 Combination Graph Data Requirements

A combination graph uses different types of data markers to display different sets of data. The data markers used are bar, area, and line. Data guidelines for combination graphs are: ■ Combination graphs require at least two sets of data or else the graph cannot show different marker types. ■ Combination graphs require at least two groups of data or else the graph cannot render an area marker or a line marker.

24.3.5 Funnel Graph Data Requirements

A funnel graph is a visual representation of data related to steps in a process. As the value for a given step or slice of the funnel approaches the quota for that slice, the slice fills. A funnel renders a three-dimensional chart that represents target and actual values, and levels by color. A funnel graph displays data where the target is considered to be 100. Therefore, if the actual value is 50 and target is 200, then 25 of the slice will be filled. Data guidelines for funnel graphs are: ■ Funnel graphs require two series or sets of data. These two sets of data serve as the target and actual data values. Threshold values appear in the graph legend. Another variation of the funnel graph requires only one set of data, where the data values shown are percentages of the total values. To produce this type of funnel Note: When you look at a bubble graph, you can identify groups of data by examining tooltips on the markers. However, identifying groups is not as important as looking more at the overall pattern of the data markers.