# Error Bars

Error bars are a graphical representation of the variability of data and are used on graphs to indicate the error, or uncertainty in a reported measurement. Currently, Vitara charts supports error bars in the following charts.

1. Vitara Bar Chart
2. Vitara Column Chart
3. Vitara Line Chart
4. Vitara Sparkline Chart

## How to set error bars in the vitara charts. <a href="#how-to-set-error-bars-in-the-vitara-charts" id="how-to-set-error-bars-in-the-vitara-charts"></a>

To set error bars in vitara charts, we need three metrics. One is the basis measure for which the error bars are calculated. ‘Error-Low Value’ and ‘Error-High Value’ are the other two measures.

## Example: <a href="#example" id="example"></a>

Consider the following example: the open and closing values of the Amazon.com, Inc. stock price for the month of November 2019. I’d want to show the day’s high and low values as error bars on the close value measure. The following attributes and metrics are utilised in the example:

**Attributes:** 1.Date

**Metrics:** 1.Open ($), 2.Close ($), 3.Day High ($), 4.Day Low ($).

### **Step 1:**

Insert a Vitara bar, column, or line chart as needed. In this example, I used a Vitara column chart. First, I added the metrics **Open ($)** and **Close ($)** to the chart.

<figure><img src="https://106821559-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FuIDde50GEkigLbPmGgLx%2Fuploads%2FeIr1woY5FYDlFUeIyU84%2Fimage.png?alt=media&#x26;token=ff6dba17-a932-4f05-9578-caf1bf93f7d9" alt=""><figcaption></figcaption></figure>

I’d like to display the error bars on the **Close ($)** metric’s bars. Insert the Day High ($) and Day Low ($) metrics into the **Tooltip** dropzone. The metric **Day Low** ($) should be set as the error bar’s low value, and the metric **Day High** ($) should be set as the error bar’s high value.

## **Step 2:**

To reveal the Edit button, move the cursor over the Vitara chart. To access the properties pane, click on the Edit button. Open the Series menu in the properties pane.

In basic terms, the series properties will be set up via the Series menu. This indicates the type of chart used to draw the series, the color of the series, and the axis for this series—primary/secondary—for a certain metric.

Edit the series properties for the measure for which you want to configure the error bars in the Series menu. For the metric Close ($) in the present example, click Edit.

<figure><img src="https://106821559-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FuIDde50GEkigLbPmGgLx%2Fuploads%2FSD3ZpTI1xMrr9xs82hfp%2Fimage.png?alt=media&#x26;token=595feb25-52f7-4359-8dc8-a6d903206b82" alt=""><figcaption></figcaption></figure>

### **Step 3:**

In the series properties there is a check box **Show Error Bars**. Click on this check box to enable **Error Bars** in the chart.

<figure><img src="https://106821559-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FuIDde50GEkigLbPmGgLx%2Fuploads%2FJAV2QBs7IX3zapGQ0NtO%2Fimage.png?alt=media&#x26;token=cb985850-f604-45df-b2cc-4cd70db3a90b" alt=""><figcaption></figcaption></figure>

## **Step 4:**

When error bars are enabled, the drop-down list boxes to set low and high values for error bars appear in the series properties menu. Select the measurements you wish to designate as low and high values by expanding the drop-down list. then decide on the error bar’s color. Finally, press the Apply button.

<figure><img src="https://106821559-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FuIDde50GEkigLbPmGgLx%2Fuploads%2Fo7Wo18IckkbJQGmcQ4yG%2Fimage.png?alt=media&#x26;token=db2f8118-f0ee-4a82-a67f-ba5f64eb5778" alt=""><figcaption></figcaption></figure>

Below is the screenshot of Vitara colum chart showing error bars on the metric **Close ($)**.

<figure><img src="https://106821559-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FuIDde50GEkigLbPmGgLx%2Fuploads%2FcR0m3GwbecmGRrn3EekB%2Fimage.png?alt=media&#x26;token=2f5bf66b-4c7b-4d9c-a304-bd0f01e8c29a" alt=""><figcaption></figcaption></figure>

For the same example, below is the screenshot of the vitara line chart showing error bars.

<figure><img src="https://106821559-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FuIDde50GEkigLbPmGgLx%2Fuploads%2Ff59bYVhaQ4eH40K2mEZx%2Fimage.png?alt=media&#x26;token=bef8337a-2190-4295-ba19-522e43f48607" alt=""><figcaption></figcaption></figure>
