When creating custom expressions, you may need to refer to an axis from the visualization in the expression. Below is a list of the available axes for different visualization types. Some of the axes can be useful in OVER expressions, whereas others are only used when defining rules or reference lines.
The term axis, in this context, does not only refer to the X and Y axes, but is a general term for the mapping of data to a dimension represented in the visualization: coloring is controlled by the Color axis, marker shape by the Shape axis and so on.
The syntax when referring to axes in an expression is [Axis.Axis Name]. For example, if the Axis Name is "X", the expression should refer to [Axis.X]. Note that the actual names to use may be different in two similar looking visualizations. For example, in the cross table you would refer to Axis.Columns whereas in a heat map you would use Axis.X for similarly set up visualizations.
It does not make any sense to include the axis you are creating the expression for in an OVER expression. Instead, you would probably want to use the categorization on the X-axis or the Color axis when defining an OVER expression on the Y-axis.
Axes to use in OVER expressions and other expressions:
Visualization |
Axis (Property) |
Axis Name Used in Expression |
Cross Table |
Columns Rows |
Columns Rows |
Sparkline |
Rows X-axis |
Rows* X |
Calculated Value |
Rows |
Rows* |
Icon |
Rows |
Rows* |
Bullet Graph |
Rows |
Rows* |
Bar Chart |
Category axis Color by |
X Color |
Line Chart |
X-axis Color by Line by Line by + Color by |
X Color Line Feature |
Combination Chart |
X-axis Color |
X Color |
Pie Chart |
Color by |
Color |
Scatter Plot |
X-axis Y-axis Color by Marker by Shape by Label by Line by |
X Y Color Marker Shape Label Line |
3D Scatter Plot |
X-axis Y-axis Z-axis Color by Marker by Shape by Label by |
X Y Z Color Marker Shape Label |
Map Chart - Feature Layer |
Color by Geometry by |
Color Geometry |
Map Chart - Marker Layer |
X-axis Y-axis Color by Marker by Shape by Label by Line by |
X Y Color Marker Shape Label Line |
5.5 Map Chart |
X-axis Y-axis Color by Marker by Shape by Label by Line by Identifier |
X Y Color Marker Shape Label Line Identifier |
Treemap |
Hierarchy |
Hierarchy |
Heat Map |
X-axis Y-axis |
X Y |
Parallel Coordinate Plot |
Line by Color by |
Line Color |
Trellis |
Columns Rows Pages Panels |
Columns Rows Pages Panels |
* The Rows axis in a graphical table can be used in OVER expressions in dynamic item columns included in that graphical table.
Example:
Sum([Sales]) OVER (AllPrevious([Axis.X]))
See OVER in Custom Expressions and Advanced Custom Expressions for more information about OVER expressions.
Axes to use in rules and reference lines only:
When defining rules (for example, for coloring, icons or calculated values) or when setting up a reference line in a visualization, you will define an expression directly using the value on that very axis. (The way to refer to the axes is slightly different in those two contexts.)
Visualization |
Axis (Property) |
Axis Name Used in Expression |
Sparkline |
Y-axis |
Y |
Calculated Value |
Value |
Value |
Icon |
Icon |
Icon |
Bar Chart |
Value axis |
Y |
Scatter Plot |
X-axis Y-axis |
X Y |
Line Chart |
Y-axis |
Y |
Combination Chart |
Y-axis |
Y |
Examples in rules:
[Axis.Color]="West"
[Axis.Value]> 10000
Example in reference line:
Avg([Y])*10
See also:
Custom Expressions Introduction