# Stacked horizontal graph showing counts of "Terms"

**URL:** https://discuss.elastic.co/t/stacked-horizontal-graph-showing-counts-of-terms/207882
**Category:** Kibana
**Created:** [November 14, 2019, 12:11pm UTC](https://discuss.elastic.co/t/stacked-horizontal-graph-showing-counts-of-terms/207882 "2019-11-14T12:11:21Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![rahul\_saini](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/rahul_saini/32/56969_2.png) [@rahul\_saini](https://discuss.elastic.co/u/rahul_saini)
#### Post date: [November 14, 2019, 12:11pm UTC](https://discuss.elastic.co/t/stacked-horizontal-graph-showing-counts-of-terms/207882/1 "2019-11-14T12:11:21Z")

</div>

Hello,

I've 3 `Terms` in my Elasticsearch data, viz. _Happy, Sad & Neutral_.  
I'm taking this survey data for a set of users say 200 people.

I want to show this data in horizontal bar, something like below:

 ![Cipart](https://us1.discourse-cdn.com/elastic/original/3X/c/a/cac7e820d03c03ab190eb74758b6b1b5f575dcf2.png)

So counts will be X-axis & terms will be Y-axis in stacked fashion.

I'm new to Kibana and when I'm trying to show these counts, and add first metrics of Happy, it shows something like this:

 ![Snipping](https://us1.discourse-cdn.com/elastic/original/3X/6/f/6f0915908b474053127167b313f05a74a2c9ab7f.png)

Kindly suggest, what do I need to do?

_Thanks_

---

<div class="post-metadata">

### Author: ![wylie](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/wylie/32/81794_2.png) [@wylie](https://discuss.elastic.co/u/wylie)
#### Post date: [November 14, 2019, 4:21pm UTC](https://discuss.elastic.co/t/stacked-horizontal-graph-showing-counts-of-terms/207882/2 "2019-11-14T16:21:22Z")

</div>

Assuming you have many documents such as `{ expression: 'HAPPY' }` `{ expression: 'SAD' }` you can visualize this setting the X-axis to Terms of `expression`.

If your documents are `{ HAPPY: 1, SAD: 2, NEUTRAL: 10 }` then you need to build three filters on the X-axis, although each filter can be \*. Then for your Y-axis you can apply a SUM(Happy) or SUM(Sad)

---

<div class="post-metadata">

### Author: ![rahul\_saini](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/rahul_saini/32/56969_2.png) [@rahul\_saini](https://discuss.elastic.co/u/rahul_saini)
#### Post date: [November 18, 2019, 11:51am UTC](https://discuss.elastic.co/t/stacked-horizontal-graph-showing-counts-of-terms/207882/3 "2019-11-18T11:51:35Z")

</div>

@wylie, thanks for reponse & sorry for delay in feedback. It looks like I didn't posted the question right.  
Instead of deleting this post (as it might help someone), I've rephrased the question [here](https://discuss.elastic.co/t/stacked-horizontal-graph-showing-percentage-counts-of-multiple-terms/208304).

Would appreciate if you can suggest what am I doing wrong. Thanks

---

<div class="post-metadata">

### Author: ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)
#### Post date: [December 16, 2019, 11:51am UTC](https://discuss.elastic.co/t/stacked-horizontal-graph-showing-counts-of-terms/207882/4 "2019-12-16T11:51:37Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
