Top.Mail.Ru
Combined Bar Chart
CTRL+K

Combined Bar Chart

In this article
  • Combined Bar Chart
  • Widget Settings
  • Data Settings
  • Display Settings
  • Filtering Settings
  • Widget Configuration in YAML
  • Data Settings in YAML
  • Display Settings in YAML
  • Filtering Settings in YAML
  • Example of a Configured Widget in the YAML Editor

A Combined Bar Chart is useful when you need to display multiple measures with different scales.

Example of a Combined Bar Chart

Widget Settings

In addition to the common widget settings, this widget has unique configuration options.

Data Settings

You can add dimensions and measures to the widget. For dimensions, you can hide empty values, add click actions, and configure the Display parameter (Always / By variable / By formula).

Measures offer additional settings.

Type

Controls how the chart is displayed: Auto (default), as bars, or as a line with points. When using a line, you can adjust its thickness.

Additionally, you can enable Data labels for a measure and specify their size.

Note

The available color configuration modes for dimensions and measures depend on the widget’s setup and the selected chart type: Auto, Bar, or Line.

1 dimension
1 measureChart type Line

For the dimension:
Color settings are unavailable

For the measure, the following modes are available:
1. Solid

Chart type Bar

For the dimension, the following modes are available:
1. Disabled
2. By values (Solid-mode rules apply to values)
3. By rule (rules based on the added dimension apply to values)

For the measure, the following modes are available:
1. Solid
2. Gradient
3. Custom
Multiple measuresFor the dimension (any chart type):
Color settings are unavailable

For a measure with type Auto:
Color settings are unavailable

For a measure with type Bar, the following modes are available:
1. Auto
2. Solid
3. By rule (Solid-mode rules apply to values)

For a measure with type Line, the following modes are available:
1. Auto
2. Solid
3. By rule (Solid-mode rules apply to values)

Display Settings

Text Size

Controls the font size within the widget, excluding measure Data labels.

Dimension Limit

Controls the number of bars or points displayed on the chart.

Hide Empty Values

Enable this option to exclude empty values from the chart.

Hint

When enabled, hovering over a bar or point in Browse mode displays a hint with detailed information about the data shown.

Type

If the chart contains two or more bar-type measures, you can choose how bars are displayed: stacked or grouped.

Orientation

Controls the direction in which bars are displayed:

  • Auto (default)
  • Vertical
  • Left-aligned vertical
  • Right-aligned vertical

If the dimension uses a time-based format, the chart orientation is vertical; otherwise, it is horizontal.

Bar Width

Default: Auto (20 pixels for horizontal orientation, 36 pixels for vertical). Acceptable values range from 12 to 100 pixels. The input value sets the maximum bar width, provided there is enough space on the chart (gaps between bars are at least as wide as the bars themselves). If space is insufficient, the bar width is automatically reduced to the maximum possible for each specific case.

Note
  • This parameter is available only if the widget contains at least one bar-type measure.
  • If bars are displayed in grouped mode, the configured width applies to all bars.

Line Smoothing

Enable this option to make lines on the chart smoother (available only for the line-with-points display mode).

Legend

Details on working with the legend are described on the Widgets page.

X-Axis

For the X-axis, you can enable a title and configure label rotation and height.

Y-Axis

For the Y-axis, you can enable a title and set label width.

Y2-Axis

For the Y2-axis, you can enable a title, set label width, and define a value range.

Note
  • Display of all axes can be toggled on or off.
  • If a measure’s value exceeds the axis range, the chart automatically scales to accommodate it. Values outside the defined range are displayed without points beyond the visible area of the chart.

Filtering Settings

The widget supports standard filtering settings.

Note
  • A filter configured within the widget cannot be removed in Browse mode.
  • If a click-based filter is applied to the widget, the selected points on the line are highlighted.

Widget Configuration in YAML

The widget can be edited not only visually but also in the YAML editor. The table below lists the keys and values you can use for configuration. For details on working with the value key, refer to Dimension and Measure Values in YAML. Supported data formats are described on the corresponding page. General widget parameters are covered in Widget Configuration in YAML.

Data Settings in YAML

KeyTypeDefinition
titlestringTitle
showMarkdownbooleanDescription
markdownTextstringDescription text
markdownMeasuresMeasures in description
dimensionsDimensions
measuresMeasures
sortingSorting

Dimensions in YAML (key: dimensions)

KeyTypeDefinition
namestringDimension name
valueDimension formula
dbDataTypeenumDimension data type
formatenumFormat
formattingenumFormatting
formattingTemplatestringCustom formatting
Only available for CUSTOM (Custom) formatting
hideEmptyValuesbooleanHide empty values
hierarchyDimensionsHierarchy dimensions
If this parameter is added, the indicator is treated as hierarchical
onClickClick actions
Not displayed if the indicator is hierarchical
colorColor:
- DISABLED — Disabled
- VALUES — By values
- RULE — By rule
Not applied if:
1. More than one measure is defined
2. Only one measure exists with type LINE
3. The dimension is hierarchical
displayConditionDisplay (display condition)
arrayNestingbooleanArray nesting
Hierarchical Dimension (key: hierarchyDimensions)
KeyTypeDefinition
namestringDimension name
valueDimension formula
dbDataTypeenumDimension data type
formatenumFormat
formattingenumFormatting
formattingTemplatestringCustom formatting
Only available for CUSTOM (Custom) formatting
hideEmptyValuesbooleanHide empty values
onClickClick actions
colorColor:
- DISABLED — Disabled
- VALUES — By values
- RULE — By rule
Not applied if:
1. More than one measure is defined
2. Only one measure exists with type LINE
displayConditionDisplay (display condition)
arrayNestingbooleanArray nesting

Measures in YAML (key: measures)

KeyTypeDefinition
namestringMeasure name
valueMeasure formula
dbDataTypeenumMeasure data type
formatenumFormat
formattingenumFormatting
formattingTemplatestringCustom formatting
Only available for CUSTOM (Custom) formatting
displayMeasure display type
showLabelsData labels
colorColor
1. For measures with type AUTO:
- AUTO — Auto
2. For measures with type BAR:
- AUTO — Auto
- BASE — Solid
- FORMULA — By formula
- RULE — By rule
3. For measures with type LINE:
- AUTO — Auto
- BASE — Solid
- RULE — By rule
displayConditionDisplay (display condition)
Measure Display Type in YAML (key: display)
KeyTypeDefinition
modeenumType:
- AUTO — Auto
- BAR — Bar
- LINE — Line
lineThicknessenumLine thickness:
- THIN — Thin
- THICK — Thick
Only available for type LINE
Value Labels in YAML (key: showLabels)
KeyTypeDefinition
enabledbooleanLabels on/off
sizenumberLabel size

Display Settings in YAML

KeyTypeDefinition
paddingsstringSide paddings
titleSizenumberTitle size
titleColorTitle color:
- AUTO — Auto
- BASE — Solid
titleWeightenumFont weight:
- NORMAL — Normal
- BOLD — Bold
markdownTextSizenumberDescription text
Specifies the Markdown description font size. Available only if the Description toggle is enabled
textSizenumberText size
dimensionLimitnumberDimension limit
hideEmptyValuesbooleanHide empty values
showHintbooleanHint
chartTypeenumChart type:
- STACK — Stacked
- GROUP — Grouped
Applies only if more than one measure uses type BAR
orientationenumOrientation:
- AUTO — Auto
- HORIZONTAL — Horizontal
- VERTICAL-LEFT — Vertical, left-aligned
- VERTICAL-RIGHT — Vertical, right-aligned
lineSmoothingbooleanLine smoothing
legendLegend
showTotalLabelsTotal Data labels
Only available for type STACK
xAxisX-axis settings
x2AxisX2-axis settings
yAxisY-axis settings
y2AxisY2-axis settings
barWidthnumberBar width

Total Value Labels (key: showTotalLabels)

KeyTypeDefinition
enabledbooleanTotal labels on/off
sizenumberLabel size

X-Axis Settings (key: xAxis)

KeyTypeDefinition
enabledbooleanX-axis on/off
rotationnumberLabel rotation
heightnumberLabel height
showTitlebooleanTitle

X2-Axis Settings (key: x2Axis)

KeyTypeDefinition
enabledbooleanX2-axis on/off
rotationnumberLabel rotation
heightnumberLabel height
showTitlebooleanTitle
rangeSwitchbooleanEnable/disable range
rangeRange values
Range Values in YAML (key: range)
KeyTypeDefinition
minnumberMinimum value
maxnumberMaximum value

Y-Axis Settings (key: yAxis)

KeyTypeDefinition
enabledbooleanY-axis on/off
widthnumberLabel width
showTitlebooleanTitle

Y2-Axis Settings (key: y2Axis)

KeyTypeDefinition
enabledbooleanY2-axis on/off
widthnumberLabel width
showTitlebooleanTitle
rangeSwitchbooleanEnable/disable range
rangeRange values

Filtering Settings in YAML

KeyTypeDefinition
filterModeenumFilter mode:
- DEFAULT — Default
- SINGLE — Single selection
- DISABLED — Disabled
ignoreFiltersbooleanIgnore filters
filtersFilters
aggregateFiltersAggregate filters
stateNamestringState

Example of a Configured Widget in the YAML Editor

- key: combined-bar-chart
  apiVersion: "16"
  type: COMBINED_CHART
  settings:
    title: ""
    titleSize: 14
    titleColor:
      mode: AUTO
    titleWeight: NORMAL
    showMarkdown: false
    markdownMeasures: []
    markdownText: ""
    textSize: 12
    displayCondition:
      mode: DISABLED
    showTotalLabels:
      enabled: false
      size: 12
    xAxis:
      enabled: true
      showTitle: false
    x2Axis:
      enabled: true
      showTitle: false
      rangeSwitch: false
      range: {}
    yAxis:
      enabled: true
      showTitle: false
    y2Axis:
      enabled: true
      showTitle: false
      rangeSwitch: false
      range: {}
    dimensionLimit: 15
    dimensions:
      - name: Store
        value:
          mode: FORMULA
          formula: '"store"."Store"'
        dbDataType: STRING
        format: STRING
        formatting: AUTO
        displayCondition:
          mode: DISABLED
        color:
          mode: DISABLED
        onClick: []
    measures:
      - name: Profitability
        value:
          mode: FORMULA
          formula: (sum("sale"."Sales amount") - sum("sale"."Cost") )/
            sum("sale"."Sales amount") * 100
        dbDataType: FLOAT
        format: NUMBER
        formatting: x.x[%]
        display:
          mode: STACK
          lineThickness: THIN
        showLabels:
          enabled: true
          size: 12
        color:
          mode: BASE
          value: "#c5d4e0"
        displayCondition:
          mode: DISABLED
        formattingTemplate: ""
      - name: Cost
        value:
          mode: TEMPLATE
          dbType: CH
          tableName: sale
          columnName: Cost
          templateName: sum
        dbDataType: FLOAT
        format: NUMBER
        formatting: AUTO
        display:
          mode: LINE
          lineThickness: THICK
        showLabels:
          enabled: true
          size: 12
        color:
          mode: BASE
          value: "#078936"
        displayCondition:
          mode: DISABLED
    chartType: STACK
    lineSmoothing: true
    orientation: HORIZONTAL
    legend:
      position: BOTTOM
      align: CENTER
    filterMode: DEFAULT
    ignoreFilters: false
    stateName: null
    filters: []
    sorting: []

Was the article helpful?

Yes
No
Previous
Strip Сhart
We use cookies to improve our website for you.