> For the complete documentation index, see [llms.txt](https://docs.appfarm.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.appfarm.io/library/ui-components/advanced-bar-chart.md).

# Advanced bar chart

The Advanced Bar Chart displays data as a series of rectangular bars with heights or lengths proportional to the represented values, which can also be shown in 3D. It is possible to create more complex charts than with [Basic Bar Charts](https://docs.appfarm.io/library/ui-components/basic-bar-chart.md). For example, the Category Property is not limited to some data types and more visual properties are available.

## Usage

Advanced Bar Charts are used to compare values.

{% hint style="info" %}
Showroom: [Advanced Bar Charts example](https://showroom.appfarm.app/ui-components/advanced-bar-chart), with its setup in Appfarm Create ([register](https://showroom.appfarm.app/sign-up) for access).
{% endhint %}

## Properties

| Property                  | Description                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            |
| ------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| **Data source**           | Select a data source to display as a chart.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            |
| **Filter**                | Apply a filter to the selected data source.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            |
| **Conditional filters**   | Create conditional filters to apply to the selected data source.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       |
| **Category property**     | Select a data source to display as X Axis in the chart.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                |
| **Hide empty**            | <p>Visible when <strong>Category property</strong> is selected.</p><p>Enable to hide categories without content.</p>                                                                                                                                                                                                                                                                                                                                                                                                                                   |
| **Tristate**              | <p>Visible when <strong>Show legend</strong> is enabled and the <strong>Category property</strong> is of data type Boolean.</p><p>By default, false and unset values are treated the same. Enable to treat unset values as a separate category.</p>                                                                                                                                                                                                                                                                                                    |
| **Data grouping**         | <p>Visible when <strong>Category property of data type Datetime</strong> is selected.</p><p>Add one or more groupings. Each grouping has a <strong>Group by</strong> dimension to group the data by, a <strong>Custom format</strong> to override the date format (check <a href="https://momentjs.com/docs/#/displaying/format/">momentjs</a> for a complete reference), and an <strong>Enabled</strong> setting. The first enabled grouping is used. If no grouping is enabled, all objects are displayed in the order given by the data source.</p> |
| **Value property**        | Select a data source to aggregate the data on. If no data source is selected, count will be used by default.                                                                                                                                                                                                                                                                                                                                                                                                                                           |
| **Aggregation**           | <p>Visible when <strong>Value property</strong> is selected.</p><p>Select one of the functions Count, Sum, Average, Median, Minimum or Maximum to aggregate the data on.</p>                                                                                                                                                                                                                                                                                                                                                                           |
| **Show uncategorized**    | <p>Visible when <strong>Show legend</strong> is enabled and the <strong>Category property</strong> is of data type Datetime, Enum, String or Reference (or Boolean with <strong>Tristate</strong>).</p><p>Enable to show uncategorized data as a separate category.</p>                                                                                                                                                                                                                                                                                |
| **Default name**          | <p>Read-only when a <strong>Dataset property</strong> is selected or <strong>Static datasets</strong> is enabled.</p><p>Enter a default name for one dataset. If no dataset property is selected, only one dataset will be shown.</p>                                                                                                                                                                                                                                                                                                                  |
| **Dataset property**      | <p>Read-only when no <strong>Data source</strong> is selected or <strong>Static datasets</strong> is enabled.</p><p>Select a data source to split the data into datasets based on this property. If no data source is selected, all the data will be treated as a single dataset.</p>                                                                                                                                                                                                                                                                  |
| **Color value**           | <p>Visible when a <strong>Dataset property</strong> that is not an Enumerated Type is selected (for example Boolean, Integer, Duration or Reference).</p><p>Set the dataset color from a data source of type Enum Type.</p>                                                                                                                                                                                                                                                                                                                            |
| **Use enum colors**       | <p>Visible when <strong>Dataset property of type Enumerated Type</strong> is selected.</p><p>Enable to use the colors defined in each Enum Value.</p>                                                                                                                                                                                                                                                                                                                                                                                                  |
| **Hide empty** (Datasets) | Enable to hide a dataset that has no data in any category.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                             |
| **Datasets**              | <p>Visible when the <strong>Dataset property</strong> is a reference.</p><p>Select the data source that holds the referenced objects, so they can be used as datasets.</p>                                                                                                                                                                                                                                                                                                                                                                             |
| **Display value**         | <p>Visible when <strong>Datasets</strong> is set.</p><p>Select a property of the dataset data source to display for each dataset.</p>                                                                                                                                                                                                                                                                                                                                                                                                                  |
| **Limit datasets**        | <p>Visible when <strong>Dataset property of type Enumerated Type</strong> is selected.</p><p>Enable to limit the dataset property by one or more Enum Values.</p>                                                                                                                                                                                                                                                                                                                                                                                      |
| **Stack datasets**        | <p>Visible when a <strong>Dataset property</strong> is selected or <strong>Static datasets</strong> is enabled.</p><p>Select None (default), Normal or To 100% to stack the datasets.</p>                                                                                                                                                                                                                                                                                                                                                              |
| **Static datasets**       | <p>Only visible when <strong>Dataset property</strong> is not defined.</p><p>Enable to use static datasets instead of defining a dataset property.</p>                                                                                                                                                                                                                                                                                                                                                                                                 |
| **Dataset name**          | <p>Visible when <strong>Static datasets</strong> is enabled.</p><p>Enter a static name for the dataset or bind it to a data source or function.</p>                                                                                                                                                                                                                                                                                                                                                                                                    |
| **Filter**                | <p>Visible when <strong>Static datasets</strong> is enabled.</p><p>Apply a filter to the selected data source.</p>                                                                                                                                                                                                                                                                                                                                                                                                                                     |
| **Value override**        | <p>Visible when <strong>Static datasets</strong> is enabled.</p><p>Override the value if the value used for the dataset is stored in another property than the main value property.</p>                                                                                                                                                                                                                                                                                                                                                                |
| **Color**                 | <p>Visible when <strong>Static datasets</strong> is enabled.</p><p>Define a color for the dataset.</p>                                                                                                                                                                                                                                                                                                                                                                                                                                                 |
| **Disable gradient**      | Enable to lighten up the color value.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  |
| **3D**                    | Enable to display the chart in 3D. When enabled, set **Alpha**, **Beta**, **Depth** and **Column depth**.                                                                                                                                                                                                                                                                                                                                                                                                                                              |
| **Alpha**                 | <p>Visible when <strong>3D</strong> is enabled.</p><p>Set the vertical viewing angle, from 0 to 45. Default is 15.</p>                                                                                                                                                                                                                                                                                                                                                                                                                                 |
| **Beta**                  | <p>Visible when <strong>3D</strong> is enabled.</p><p>Set the horizontal viewing angle, from -45 to 45. Default is 15.</p>                                                                                                                                                                                                                                                                                                                                                                                                                             |
| **Depth**                 | <p>Visible when <strong>3D</strong> is enabled.</p><p>Set the depth of the chart, from 20 to 100. Default is 50.</p>                                                                                                                                                                                                                                                                                                                                                                                                                                   |
| **Column depth**          | <p>Visible when <strong>3D</strong> is enabled.</p><p>Set the depth of the columns, from 20 to 100. Default is 25.</p>                                                                                                                                                                                                                                                                                                                                                                                                                                 |
| **Title**                 | Enter a static title or bind it to a data source, function, date now or date today.                                                                                                                                                                                                                                                                                                                                                                                                                                                                    |
| **Subtitle**              | Enter a static title or bind it to a data source, function, date now or date today.                                                                                                                                                                                                                                                                                                                                                                                                                                                                    |
| **Show legend**           | Enable to show a legend.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               |
| **Legend position**       | <p>Visible when <strong>Show legend</strong> is enabled.</p><p>Position the legend on the top, left, bottom or right side of the chart.</p>                                                                                                                                                                                                                                                                                                                                                                                                            |
| **Disable animation**     | Enable to stop animation of the chart.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 |
| **Sort by data**          | Enable to sort the categories by ascending value. To sort by descending value, also enable **Reverse axis** on the Category Axis (X).                                                                                                                                                                                                                                                                                                                                                                                                                  |
| **Zoom type**             | Define if the X Axis, Y Axis or both should be zoomable. By default, None is selected.                                                                                                                                                                                                                                                                                                                                                                                                                                                                 |
| **Show data labels**      | Enable to show data labels above each data point.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      |
| **Label decimals**        | <p>Visible when <strong>Show data labels</strong> is enabled.</p><p>Define decimals to override the number of decimals shown in the data labels.</p>                                                                                                                                                                                                                                                                                                                                                                                                   |
| **No hover**              | Enable to turn off hover effects, tooltips and click events on the chart's series. **On series click** then no longer runs.                                                                                                                                                                                                                                                                                                                                                                                                                            |
| **Tooltip decimals**      | Define decimals to override the number of decimals shown for the y value in the tooltip.                                                                                                                                                                                                                                                                                                                                                                                                                                                               |
| **Polar**                 | Enable to transform the chart into the polar coordinate system. The chart is then displayed as a polar/radar chart.                                                                                                                                                                                                                                                                                                                                                                                                                                    |
| **Invert axes**           | Enable to invert both X Axis and Y Axis with each other.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               |
| **Axis title**            | Enter a static title or bind it to a data source, function, date now or date today.                                                                                                                                                                                                                                                                                                                                                                                                                                                                    |
| **Axis type**             | Select a type for the axis: Auto, Linear, Logarithmic, Datetime or Category.                                                                                                                                                                                                                                                                                                                                                                                                                                                                           |
| **Tick interval**         | Set an interval for ticks on the axis. If the interval is too dense to be displayed, some ticks will be removed automatically. Note that axes with data type Datetime are based on milliseconds.                                                                                                                                                                                                                                                                                                                                                       |
| **Tick Mark Placement**   | <p>Only applicable for <strong>Category Axis</strong> (X Axis).</p><p>Define the position of the tick marks on the X Axis. If Auto is selected and the interval is 1, the tick mark is placed between categories, else the tick mark is placed in the center of the category. If Between is selected, the tick mark is always placed between categories. If On is selected, the tick mark is always placed in the center of the category.</p>                                                                                                          |
| **Min value**             | Define the minimum value on the axis. If no value is set, it will automatically adjust to data.                                                                                                                                                                                                                                                                                                                                                                                                                                                        |
| **Extend min to data**    | <p>Visible when <strong>Min value</strong> is set.</p><p>Enable to extend the axis minimum to the lowest value in the data shown.</p>                                                                                                                                                                                                                                                                                                                                                                                                                  |
| **Max value**             | Define the maximum value on the axis. If no value is set, it will automatically adjust to data.                                                                                                                                                                                                                                                                                                                                                                                                                                                        |
| **Extend max to data**    | <p>Visible when <strong>Max value</strong> is set.</p><p>Enable to extend the axis maximum to the highest value in the data shown.</p>                                                                                                                                                                                                                                                                                                                                                                                                                 |
| **Grid lines**            | Enable to show grid lines on the axis.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 |
| **Crosshair**             | Enable a crosshair on the axis.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        |
| **Hide axis**             | Enable to hide the axis.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               |
| **Reverse axis**          | Enable to reverse the axis in order to display the values from highest to lowest.                                                                                                                                                                                                                                                                                                                                                                                                                                                                      |
| **Place opposite**        | Enable to place the axis on the opposite side of the chart.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            |
| **Grid line shape**       | <p>Visible on the Value Axis (Y) when <strong>Polar</strong> is enabled.</p><p>Select Auto, Circle or Polygon to draw the grid lines as circles or straight lines between categories. Default is Auto.</p>                                                                                                                                                                                                                                                                                                                                             |
| **Threshold lines**       | Add plot threshold indicators by defining a name, visibility, type (line or band), start value and color.                                                                                                                                                                                                                                                                                                                                                                                                                                              |
| **Event handlers**        | Add an **On series click** action to run when a data series is clicked. See [Understand charts](https://docs.appfarm.io/how-to/user-interface/understand-charts.md#respond-to-clicks-with-on-series-click) for the available action params and behavior.                                                                                                                                                                                                                                                                                               |


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.appfarm.io/library/ui-components/advanced-bar-chart.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
