Version

Working with Column Line Chart Data

This topic discusses useful information that will help you to ensure that your data is rendered properly in the 2D column line chart.

Data Requirements

While the Chart control allows you to easily point the chart to your own custom data, it is important that you are supplying the appropriate amount and type of data that the chart requires. If the data does not meet the minimum requirements based on the type of chart that you are using, an error will be generated.

The following is a list of data requirements for column line charts:

  • The data set contains one or more numeric columns. Note that it is recommended that the data set contains two or more numeric columns so that each line can have two or more points.

  • The data set contains at least one row.

Note
Note

If you are using multiple data sources, set the UltraChart.ColumnLineChart.ColumnData.SwapRowsAndColumns and UltraChart.ColumnLineChart.LineData.SwapRowsAndColumns properties to True.

Mapping Data to Column Line Charts

The chart data is rendered using the following rules:

Column Data

  • Each row is drawn separately as a group of columns. These groups of columns are called "series". Each series displays series labels below the x-axis. Data values are represented by the height of the column along the y-axis.

  • The x-axis (or horizontal axis) is a SetLabelAxis object, with the points evenly spaced apart for each item (point). The y-axis, or vertical axis, is the numeric axis. Labels on the y-axis can be formatted using the FormatString property and a "numeric format":

UltraChart.Axis.Y.Labels.ItemFormatString = "<DATA_VALUE:##.##>"

Line Data

  • Each row is drawn as a single line (or area) on the chart, with a number of points in the line equal to the count of numeric columns in the data set.

  • The first numeric column encountered in the data will be used for the value of the first point, the second numeric column will be used for the second point, and so on.

  • The x2-axis (or top horizontal axis), is a "Set Label" axis, with the points evenly spaced apart for each item (point). The y2-axis, or right vertical axis, is the numeric axis. Labels on the y2-axis can be formatted using the FormatString property and a “numeric format”:

UltraChart.Axis.Y2.Labels.ItemFormatString = "<DATA_VALUE:##.##>"