ChartDirector Ver 5.0 Release Notes
This document describes the enhancements and bug fixes in ChartDirector Ver 5.0 comparing
to ChartDirector Ver 4.1. For enhancements in earlier versions of ChartDirector, please
refer to the release notes archive.
Enhancements in Ver 5.0
3D Surface Chart
3D Surface Chart is a new chart type in ChartDirector Ver 5.0. It accepts (x, y,
z) points as input, and computes a surface that fits the points using linear or
spline surface interpolation. It then draws the surface in 3D and colors the
surface based on the z value.
The key features are:
Pyramid/Cone/Funnel Charts
Pyramid/Cone/Funnel Charts are new chart types in ChartDirector Ver 5.0. Like a
pie chart, they are mainly used for visualizing relative magnitudes. But instead
of using a pie, a pyramid, cone or funnel is used. The pyramid, cone or funnel
is sliced horizontally into layers, with the layer height proportional to the
data value.
The key features are:
Contour Layer
Contour Layer is a new layer type in XY charts. It accepts (x, y, z) points as
input, and computes a surface that fits the points using linear or spline
surface interpolation. It then colors the xy plan based on the z value of the
surface, and draw contours to join points with the same z value.
The key features are:
SVG (Scalable Vector Graphics) Support
In additional to raster images, ChartDirector Ver 5.0 can output true vector
graphics images in SVG and SVGZ (compressed SVG) formats.
Pie Chart Shading Effects
ChartDirector Ver 5.0 adds a number of pie chart shading modes, including:
Negative Data Values in Pie Charts
In previous versions of ChartDirector, negative values in pie charts are not
supported. For example, if the values are 2, -1, -1, the behaviour is undefined.
If negative values are present, they must be converted to positive values before
passing the data to pie chart.
Negative values are now supported in ChartDirector Ver 5.0. They are treated as if they are positive. For example, if the data values are 2, -1, -1, the pie will contain 3 sectors of 50%, 25%, 25%. The sector labels will still display the values as negative. Inner Sector Border
Each sector in a pie chart can now have a border of configurable color and
thickness lying internal to the sector (and hence will not overlap with
neighbouring sectors despite the thichness of the border).
Logarithmic, Exponential, Polynomial and Constrained Linear Regression
Previous versions of ChartDirector support using linear regression to compute
an optimal straight line that best fits a set of points. ChartDirector Ver 5.0
adds support for logarithmic, exponential, polynomial, and constrained linear
regression (a linear regression that always passes through the origin). Like
linear regression, these new types of regressions include confidence and
prediction bands.
Monotonic Spline Curve
ChartDirector has always supported line and spline charts in which the lines and
spline curves can flow in any direction (not limited to left to right).
ChartDirector simply joins the data points with lines or spline curves in the
order that the data points are passed to ChartDirector.
Due to the nature of splines, it is possible for a spline curve to "overshoot and flow back" for highly even data points. For data points that flow from left to right (which is the most common case), it may be undesirable if the curve overshoot in the horizontal direction (possible for data points with highly uneven horizontal spacing). ChartDirector Ver 5.0 supports monotonic constraints for spline curves. For example, if the data points flow from left to right (monotonic in the horizontal direction), ChartDirector can ensure the spline curve also flows strictly from left to right (that is, never overshoots in the horizontal direction). The monotonic constraint can also be placed on the vertical direction, or on both directions. CDML Table
CDML Table is a new text box container object introduced in ChartDirector Ver
5.0. Each cell in the table is a text box object, and can have independent
background colors, rasied effects and font styles. A cell can span more than one
row and/or column. The contents of the a cell can be specified using CDML
(ChartDirector Mark Up Language), and so the cell can contain text as well as
images.
A CDML Table can be created as a free floating object, or docked to an XY chart axis for containing the axis labels. Using CDML Table for Axis Labels
For a label based axis, ChartDirector can generate a CDML Table to contain the
labels. The CDML Table will be docked to the axis. Rows and/or columns can be
added to the table to display additional information.
A common application is to dock a CDML table under the x-axis, and add charting data as additional rows to the table. This creates a chart with the data values tabulated under the x-axis, which is a useful alternative to putting data labels directly on the bars or data points on the chart. Legend Icon As CDML Text
ChartDirector Ver 5.0 allows the legend icon that represents an XYChart data
series to be retrieved as CDML (ChartDirector Mark Up Language) text. As text,
it can be combined with other text, and put into various text containers (text
box, CDML table, etc). For example, one can use this feature with a CDML table
to create a custom legend box. Another common usage is to use the icon to label
the data series in a CDML table docked under the x-axis.
Enabling Extended Legend Icons
ChartDirector supports two legend icon styles. Normally, the icons will be
colored boxes representing the colors of the data sets. However, if the chart
contains data lines with line styles, data symbols or if bar shapes are used,
the legend icons will change to the extended style, which are wider and use more
space, but can show the line styles (eg. dash line style), data symbols and
bar shapes.
In some cases, line styles or data symbols are not used, but the user still wants to use extended style legend icons. In previous versions of ChartDirector, this can be achieved by using a "dummy dash line color" (eg. using a dash line style with mark and space being 1 and 0, which is equivalent to a solid line). In ChartDirector Ver 5.0, there is now an API specifically designed to switch on extended style icons. Spherical Symbols
Three new spherical symbols are data in ChartDirector Ver 5.0. Two of them are
translucent glass spheres, one deeper and one brighter. The third symbol is a
solid sphere. These symbols can be used in bubble charts to create impressive
bubbles. They can also be used as data symbols in line or scatter charts.
Brushed Metallic Color
Brushed Metallic Color is an enhancement to the standard metallic color by
adding a subtle random horizontal texture effect. A surface painted with this
color resembles a brushed metal surface. The strength of the brushed metal
texture is confgurable.
Drop Shadow
The chart frame can now cast a soft or hard drop shadow. The direction, offset,
color and softness of the shadow are configurable.
Gradient Bar Lighting Effect
Gradient Bar Lighting is a new shading effect for rectagular and polygonal bars
in a bar chart. It shades a bar with varying brightness along the length of the
bar. For a 3D bar, it also shades the top surface of a vertical bar and the right
surface of a horizontal bar with varying brightness along the depth dimension.
Cylinder Bar Lighting Effect
Previous versions of ChartDirector paint cylindrical bars with a built-in
gradient color that gives the impression of a cylinder. ChartDirector Ver 5.0
introduces configurable and accurate Cylinder Bar Lighting, in which the
brightness of the cylindrial surface is computed using the Phong lighting model
with configurable ambient, diffuse and specular lighting.
Bar Label Positioning
In previous versions of ChartDirector, data labels for bars can be put at the
far end of the bars (the far end is the end that is opposite to the baseline) or
the center of the bars. In ChartDirector Ver 5.0, data labels can be put at any
of the 9 alignment positions (top left, left, top right, left, center, right,
bottom left, bottom, bottom right).
Configurable Baseline
In previous versions of ChartDirector, for a bar or area chart, the bar or area
always start from zero. If the zero position is outside the plot area, the bar
or area will start from the border of the plot area that is closer to zero.
ChartDirector Ver 5.0 supports configurable baseline, which means the bar or area can start from any value. If the baseline is outside the plot area, the bar or area will start from the border of the plot area that is closer to the baseline. Configurable Minimum Hot Spot Size
For a bar chart or box-whisker chart (like a gantt chart), the hot spot region
is the bar or box. If the bar or box is very small or zero in size, it is
difficult or impossible to have mouse actions (eg. click or show tooltips)
on it.
ChartDirector Ver 5.0 supports configurable minimum size for the hot spot. If the bar or box shrinks below the minimum size, the hot spot will stay at the minimum size, so the user can still have mouse actions on it easily. Defining Vector By End Points
In previous versions of ChartDirector, vectors in a vector layer are specified
by their starting points, lengths, and angles. This type of vector specification
is suitable for vectorial quantities, such as wind direction and electric field
strength.
Sometimes vector layers are used to show relationships among points, rather than vectorial quantities. For example, a vector layer can be used to draw arrows to link pairs of points in a scatter layer, or to draw arrows along the line segments in a line layer. For a vector used to link two points, sometimes it is not trivial to determine its length and angle from the (x, y) coordinates of the end points. It is because they also depends on the ratio between the x-axis and y-axis scales. If the axes are auto-scaled, tbe ratio may not be known in advance. Often, additional code is needed to query the axes scales, and take them into account when computing the length and angle. In ChartDirector Ver 5.0, the vector layer is enhanced to allow vectors to be specified using the end points. This simplifies coding for cases in which vectors are used to link points. Vector Margins
When a vector is used to link between two points, it is sometimes desirable not
to terminiate the vector at precisely the points. For example, the points may be
denoted by circular symbols. Instead of terminating the vector at the center of
the circles, it may be better to shorten the vector to terminate it at the rims
of the circles.
ChartDirector Ver 5.0 supports specifying independent margins at the two end points of the vector, so that the vectors can be shortened or lengthened. Auto-Sizing of Plot Area to Fit a Bounding Box
ChartDirector Ver 5.0 can automatically adjust the position and size of the XY
chart plot area, so that the plot area, inclusive of axis labels, fits a given
bounding box. This avoids the need to explicitly reserve sufficient space for
the longest axis label, which is often unknown in advance.
Plot Area Positional Information API
In previous versions of ChartDirector, the position and size of an XY chart plot
area is specified by user code. Therefore, the user code always knows the
position and size of the plot area.
ChartDirector Ver 5.0 can automatically adjust the plot area position and size, so that the plot area, inclusive of the axis labels, fits a given bounding box. Because of this, the user code may no longer know the position and size of the plot area. New API are therefore added to allow the user code to retrieve these information. Axis Thickness
There is now an API available to get the "thickness" of an XY chart axis (the
width for a vertical axis, and the height for a horizontal axis). This
simplifies positioning of other chart objects based on the thickness of the
axis.
Z Ordering of XY Layers
In previous versions of ChartDirector, the drawing order of the layers in an XY
Chart is determined by the order that the layers are added to the chart, with
the first layer in the front. Also, all layers are drawn on top of the grid lines.
In some cases, it may be desirable to draw a layer under the grid lines. An example is the newly introduced contour layer, which is natural to draw under the grid lines. ChartDirector Ver 5.0 allows a layer to be inserted in front or behind another layer. It also allows the grid lines to be inserted in front of a given layer, instead of always behind all layers. FinanceChart Enhancement
The followings are new features added to the finance chart library:
Consistent Axis Label Formatting
In previous versions of ChartDirector, for a numeric axis, if no format is
specified, the axis labels will be independently and automatically formatted.
For example, an axis with scale 0 - 2 with a label every 0.5 unit will have
labels like 0, 0.5, 1, 1, 1.5, 2.
In ChartDirector Ver 5.0, ChartDirector will analysis all label values to determine the precison required to distinguish the values. It will then apply the same format to all label values. In the example above, the precision is 1 decimal place, so the labels will be 0.0, 0.5, 1.0, 1.5, 2.0. A new decimal place specifier "@" is added to allow a custom format string to specify this dynamically determined decimal place. Linear Ticks in Logarithmic Scale
For a logarithmic scale axis, ChartDirector can automatically generate 3 types
of ticks:
ChartDirector Ver 5.0 supports a new type of automatically generated ticks:
Tick Increment Unit
ChartDirector allows the axis labels or ticks to be offseted by an amount. This
is often used for putting the axis labels between ticks (instead of centered at
the ticks), which can be achieved by shifting either the labels or the ticks by
half the tick increment.
However, for an auto-scaled axis, the tick increment may not be unknown in advance. So it may not be trivial to determine the amount to shift. ChartDirector Ver 5.0 allows the shift to be specified in "tick increment" units, without having to know what is the tick increment. It also exposes a "{tickInc}" parameter for the tick increment, which can be used in axis label templates. This allows axis labels to show the range between the two ticks. New Numeric Formatting Method
In ChartDirector Ver 5.0, a new numeric formatting method is added:
New Platforms Support
The following operating system / programming framework combinations are added in
ChartDirector Ver 5.0.
Behaviour Changes in Ver 5.0
ChartDirector Ver 5.0 is designed to be code compatible with previous versions
of ChartDirector. This means existing code should continue to work. However, in
the following cases, the appearance of the charts produced may be slightly
different.
Pie Shading
In ChartDirector Ver 5.0, the default shading method for a 3D pie chart is to
shade the cylindrical surfaces with gradient colors for cylindrial lighting
effects. In earlier versions of ChartDirector, the cylindrical surfaces are flat
colored.
Comparing Ver 5.0 with earlier versions of ChartDirector, the pie in Ver 5.0 looks better. However, the chart also uses more colors because of the gradient shading. If you are using a 256-color image format (like GIF) and are already using a lot of colors in the pie chart, there may be insufficient colors for a smooth gradient, and you may see banding artifacts in the cylindrial surface. The PieChart.setSectorStyle API can be used to control the pie shading mode and to revert back to the old flat shading method. Cylindrial Bar Shading and Projection
In ChartDirector Ver 5.0, cylindrial bars are shaded accurately using the Phong
shading model, with configurable ambient, diffuse and specular lighting
parameters. In previous versions of ChartDirector, cylindrial bars are shaded
with a built-in gradient to emulate cylindrial lighting effects.
Comparing Ver 5.0 with earlier versions of ChartDirector, the cylindrial bars in Ver 5.0 have more saturated colors. They are also more consistent with the colors used in bars of other shapes. The 3D projection method of cylindrial bars has also been changed to be consistent with bars of other shapes. As a result, the chart looks natural when cylindrial bars and bars of other shapes are mixed together. If you are using aggregate labels for 3D cylindrial bars, you may have added code to move the labels slightly, so as to adjust for the different projection method in previous versions of ChartDirector. These adjustments are no longer needed and should be removed. Axis Label Formatting
In previous versions of ChartDirector, for a numeric axis, if no format is
specified, the axis labels will be independently and automatically formatted.
For example, an axis with scale 0 - 2 with a label every 0.5 unit will have
labels like 0, 0.5, 1, 1, 1.5, 2.
In ChartDirector Ver 5.0, ChartDirector will analysis all label values to determine a suitable format, and then apply the same format to all label values. In the example above, the labels will become 0.0, 0.5, 1.0, 1.5, 2.0. FinanceChart Color and Layout Changes
The default colors and layouts are changed slightly in the FinanceChart object:
Mac OS X Font System Changes
Earlier versions of ChartDirector on Mac OS X support specifying fonts using Mac
OS X Font Manager names. However, since Nov 2007, in order to support the then
new Mac OS X 10.5 (Leopard), ChartDirector for PHP and Perl were updated and no
longer supports Mac OS X Font Manager names. The main reasons are:
Bugs Fixed in Ver 5.0
The followings are the list of bugs that are fixed in ChartDirector Ver 5.0.
Upgrade Considerations
Code Compatibility
ChartDirector Ver 5.0 is designed to be code compatible with previous versions of
ChartDirector. This means existing code should continue to work.
Behavioural Compatibility
The charts produced by ChartDirector Ver 5.0 may be slightly different from the
charts produced by earlier versions of ChartDirector. Please refer to Behaviour Changes in Ver 5.0 for details.
License Compatibility
ChartDirector Ver 4.x licenses can upgrade to ChartDirector Ver 5.0 free of
charge. ChartDirector Ver 5.0 automatically recognizes ChartDirector Ver
4.x license keys.
If you are using an earlier ChartDirector license (on the date of purchase, the ChartDirector version was Ver 3.x or below), you would need to purchase one or more upgrades to use ChartDirector Ver 5.x. Please refer to Purchasing ChartDirector Upgrade and Subscription for details. Upgrade Procedure
To upgrade ChartDirector, simply install the new version on top of the old
version.
For ChartDirector for ASP/COM/VB, you may need to run the installer twice to upgrade ChartDirector. When the installer it first run, it will detect the existing ChartDirector and uninstall it. If the existing ChartDirector is being used by another process (such as the IIS web server), the installer may prompt you to reboot in order to complete uninstallation. After uninstallation is completed, please run the installer again to install ChartDirector. For the PHP/Perl/Python editions of ChartDirector, please remember to update the files "phpchartdir.php", "perlchartdir.pm" and "pychartdir.py". These files are the language interfaces to ChartDirector. Their versions must match exactly with that of the ChartDirector DLL or shared object. Depending on how you installed your existing ChartDirector, these files might be copied to the default module directory of your language interpreter, and/or to various scripting directories in your computer. Please ensure you update all of them. If you are using PHP or mod_perl with Apache, you may need to restart the Apache server for the upgraded ChartDirector to take effect. |