Labeling Time Series Data by Constant Interval
Time series data is data collected over time for a single or a group of variables. When using date series and time series values on the category (X) axis of a chart, it is often beneficial to see the chart with constant ranges rather than just what is in the data values. This can avoid the missing values for weekends and holidays that may leave gaps in the chart which distorts the chart and might lead to incorrect decisions. This topic presents an example to show how you can use a constant interval to label time series data on the category axis of a chart.
- Make sure SampleReports.cat is the currently open catalog file. If not, select File > Open Catalog to open it from
- Select File > New > Web Report to create a web report.
- Insert a chart in the web report as follows:
- Use WorldWideSalesBV in Data Source 1 of the catalog as the data source.
- Display in the Line 2-D chart type.
- Show Order Date on the category axis and Total Quantity on the value axis.
- Apply the following filter:
- Save the report and select the View tab to preview the chart. The chart appears as follows:
- Select the Design tab to return to design mode.
- Right-click the chart and select Format Axes > Format Category (X) Axis from the shortcut menu. Designer displays the Format Category (X) Axis dialog box.
- In the Tick Mark tab of the dialog box, select the Minor Tick Mark sub tab, select Inside in the Type box to show the minor tick marks inside the axis, and then select Show Minor Tick Mark Labels in the Option box to show the minor tick mark labels.
- Select the Scale sub tab, select the Use Constant Interval option, then set the Minimum, Maximum, Major Unit, and Minor Unit options to Fixed. Specify the minimum value to Jan 1, 2015 and the maximum value to Jan 29, 2015. Set the Major Unit and Minor Unit values to 1 and select the unit as Weeks and Days respectively which stand for 1 week and 1 day.
When specifying the Minimum/Maximum value, you can also select the calendar button to select a date and time value from the calendar if the field on the category axis is of the Date, Time, or DateTime type, or select the Formula button and select a formula to control the value. When you select a DBField from the drop-down list, Logi Report applies its first record in the database as the value. If the selected formula references a parameter, the report users can dynamically specify the minimum/maximum value at runtime.
- In the Minor Label sub tab of the Format tab, select the format in the Stack box and select Remove to delete it. Select Date/Time from the Category box, type d in the Properties text box and select Add to add the format to the Stack box. Then select OK to apply the settings.
- Double-click the line. Designer displays the Format Line dialog box.
- In the Node tab, select Use Single Color, then select true from the Show Node drop-down list to show nodes on the line, and specify the node color to #000000. Select OK to accept the settings.
- Resize the chart and preview it again. The chart now shows as follows: