> For the complete documentation index, see [llms.txt](https://tsdocs.vitaracharts.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://tsdocs.vitaracharts.com/grid-chart-guide/horizontal-bars-pins.md).

# Horizontal Bars/Pins

## Horizontal Bars/Pin <a href="#horizontal-barspin" id="horizontal-barspin"></a>

The display style property, which can be accessed from the hamburger menu, allows the user to display any given individual metric as a horizontal bar or horizontal pin’s.

It can display the scaling as bars and pins.Hover onto a metric for which the trendlines need to be applied so that the hamburger button will be displayed. Click on the hamburger button, then a menu will be opened. Hover the mouse onto ‘Display Style’, then a submenu will be opened which has the trendline charts. Please refer the below screenshot:

<figure><img src="/files/PX4tJ6HgouBay4I77Pv7" alt=""><figcaption></figcaption></figure>

First, for a metric, apply the ‘Horizontal Bars/Pins’ trendline, and then format the bar/pin color and negative color. open the format window, then set the color (e.g Green). Click the ‘Apply’ button

<figure><img src="/files/F2M2zvbzvFVtJIlnwd6N" alt=""><figcaption></figcaption></figure>

In our case, we’re displaying sales and profits by region and year, with horizontal bars for metric “profit” and horizontal pins for metric “sales”.

<figure><img src="/files/zaMaSTLTMUtnB4mfXv5h" alt=""><figcaption></figcaption></figure>

## Scaling across cells for Horizontal Bars and Pins <a href="#scaling-across-cells-for-horizontal-bars-and-pins" id="scaling-across-cells-for-horizontal-bars-and-pins"></a>

We have introduced a new Scaling option which can be found from the Hamburger tab in the Display Option under More Options.

The chart scaling is set to ‘Apply at each cell’ by default; to allow scaling, change the Scale option to ‘Same across cells.’

<figure><img src="/files/zgizk3ldWKskFfpbWNSs" alt=""><figcaption></figcaption></figure>

<figure><img src="/files/kvMymGTEjaQ6Gx8AwLVm" alt=""><figcaption></figcaption></figure>

<figure><img src="/files/Bjw83seAeGcbctfn2I0L" alt=""><figcaption></figcaption></figure>

The chart scaling is set to ‘Apply at each cell’ by default; to allow scaling, change the Scale option to ‘Same across cells.’

### How Horizontal Bars or Pins Work When All Values Are the Same? <a href="#how-horizontal-bars-or-pins-work-when-all-values-are-the-same" id="how-horizontal-bars-or-pins-work-when-all-values-are-the-same"></a>

The Horizontal Bars/Pins visualization represents data values using horizontal bars whose lengths and directions reflect the distribution of values within a column. The bar appearance dynamically adjusts depending on whether the column contains positive, negative, or zero values.

**Display Logic**

The visualization adapts based on the type of values present in the column:

* All **Zero** Values: If all values in the column are zero (e.g., \[0, 0, 0, 0]), the bar appears empty, indicating no positive or negative data distribution.
* All **Positive** Values: If all values in the column are positive (e.g., \[1, 1, 1, 1]), the visualization displays a full-length positive bar, representing that all data points are positive.
* All **Negative** Values: If all values in the column are negative (e.g., \[-1, -1, -1, -1]), the visualization displays a full-length negative bar, representing that all data points are negative.

The screenshot below illustrates this behavior.

<figure><img src="https://docs.vitaracharts.com/~gitbook/image?url=https%3A%2F%2F230207405-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FOuiTPVEbVQnzR38vviPf%252Fuploads%252FL9wZgJMz8uKqHEnU92nt%252Funknown.png%3Falt%3Dmedia%26token%3Df812bcb6-3307-47a1-b556-bd8d6b7ea82c&#x26;width=768&#x26;dpr=4&#x26;quality=100&#x26;sign=d8bdcb3&#x26;sv=2" alt=""><figcaption></figcaption></figure>
