Changes

Jump to: navigation, search

Summarize iReport Template Data

4,919 bytes removed, 17:09, 20 September 2013
no edit summary
#:[[Image:iReport Chart BarPreview.png|center|500px|''Preview with Chart'']]<div align="center">''Preview with chart''</div>
===OLDModify Bar Charts===<li>Right-click anywhere on the chart.</li><li>Select the '''Chart Properties''' option.</li><li>From the Chart Properties window, select the Chart Data tab.</li><li>From the Chart Data tab, select the Details tab.</li><li>Click the '''Add''' button.</li>:The Chart Properties window displays. By default, the Data tab should be selected. <li>The Series Expression allows you to define an added level of detail to your bar chart. To enter the series expression value:</li><ol type="a"><li>Click the [[Image:iRepEditor.png]] icon that is displayed beside the Key Expression field.</li>:The Expression editor window displays.<li>From the bottom pane, double-click the name of the attribute that contains the data that you would like to include in the chart.</li>:The expression to represent the attribute displays in the top pane.<li>In order to account for null values, you will need to modify the expression so that null values are grouped into their own group. The expression should be modified to include the bolded text below. You should replace attribute with the name of the attribute that you selected in step b above.</li>$F{''attribute''} '''!= null ? $F{attribute} : "Unknown"'''<li>Click the '''Apply''' button.</li></ol>The expression that you enter in the Series Expression field will vary based on how you want the horizontal axis to appear:*If you would like the horizontal axis of the bar chart to reflect a single attribute such as the chart displayed below, the Series Expression will be the same as the Category expression.</ol>
[[Image:iRep30.png|center|500px|''Figure 30. Bar chart –Single attribute y-axis'']]<div align="center">''Figure 30. Bar chart –Single attribute y-axis''</div> <ol>*If you would like the horizontal axis of the bar chart to reflect the values of an additional attribute, the Series Expression would be the expression for the secondary level of detail. In the example shown below, the x-axis reflects the land priorities (e.g., Low, Medium, or High). In addition to displaying the priority, the bars of the chart use a different colour to reflect those land which block water access (red) vs. those that do not block the water (blue). </ol> [[Image:iRep31.png|center|500px|''Figure 31. Bar chart with different series expression'']]<div align="center">''Figure 31. Bar chart with different series expression''</div> <ol>The Chart Properties window for this bar chart is shown below. Notice that the series expression and category expression differ.</ol> [[Image:iRep32.png|center|500px|''Figure 32. Chart Properties – Different series and category expressions'']]<div align="center">''Figure 32. Chart Properties – Different series and category expressions''</div> <ol>*If you selected one of the stacked bar chart options, the series expression will be used to determine the segments of each bar. In the following figure, the series expression creates red and blue segments in each bar to indicate whether or not water access is blocked.</ol> [[Image:iRep33.png|center|500px|''Figure 33. Stacked bar chart'']]<div align="center">''Figure 33. Stacked bar chart''</div> <ol start="14"><li>The Category Expression is the major grouping of the horizontal axis. To enter the category expression:</li><ol type="a"><li>Click the [[Image:iRepEditor.png]] icon that is displayed beside the Category expression field.</li>:The Expression editor window displays.<li>From the bottom pane, double-click the name of the attribute that contains the data that you would like to include in the chart.</li>:The expression to represent the attribute displays in the top pane.<li>In order to account for null values, you will need to modify the expression so that null values are grouped into their own group. The expression should be modified to include the bolded text below. You should replace attribute with the name of the attribute that you selected in step b above.</li>$F{''attribute''} '''!= null ? $F{attribute} : "Unknown"'''<li>Click the '''Apply''' button.</li></ol><li>The '''Value Expression''' field contains the expression that returns the numeric value for the key.</li><ol type="a"><li>Click the [[Image:iRepEditor.png]] icon that is displayed beside the Value Expression field.</li>:The Expression editor window displays.<li>From the Objects and expressions tab, select '''Variables''' from the left pane.</li><li>From the middle pane at the bottom of the Expression editor window, double-click the name of the variable that was created to store the total.</li><li>Click the '''Apply''' button.</li></ol><li>Click the '''OK''' button.</li>:The Chart Properties window closes.<li>Click the '''Close''' button.</li>:The Chart Properties window closes.<li>Save the report by either clicking the [[Image:iRepSave.png]] icon, or by selecting the '''Save''' option from the '''File''' menu.</li></ol> ===Grouped Bar Chart===__NOEDITSECTION__
The horizontal axis of the bar charts discussed in the previous section compared the values of a single variable. For example, the bar chart below compares the number of different activity types.
319
edits

Navigation menu