# Dividing Value of Chart

**URL:** https://discuss.elastic.co/t/dividing-value-of-chart/108873
**Category:** Kibana
**Created:** [November 23, 2017, 11:28am UTC](https://discuss.elastic.co/t/dividing-value-of-chart/108873 "2017-11-23T11:28:15Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![v.abhishek](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/v.abhishek/32/35345_2.png) [@v.abhishek](https://discuss.elastic.co/u/v.abhishek)
#### Post date: [November 23, 2017, 11:28am UTC](https://discuss.elastic.co/t/dividing-value-of-chart/108873/1 "2017-11-23T11:28:15Z")

</div>

Hi,

I am new to Kibana and wanted your views on a simple query.  
I am trying to create Horizontal chart, where I would like to divide the count of one field by 3 while displaying it as a chart.  
Can you please help me to understand how can I achieve it?

Thanks  
Abhishek

---

<div class="post-metadata">

### Author: ![dadoonet](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dadoonet/32/137187_2.png) [@dadoonet](https://discuss.elastic.co/u/dadoonet)
#### Post date: [November 23, 2017, 2:11pm UTC](https://discuss.elastic.co/t/dividing-value-of-chart/108873/2 "2017-11-23T14:11:54Z")

</div>

Moved to #kibana

---

<div class="post-metadata">

### Author: ![timroes](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/timroes/32/19712_2.png) [@timroes](https://discuss.elastic.co/u/timroes)
#### Post date: [November 23, 2017, 3:40pm UTC](https://discuss.elastic.co/t/dividing-value-of-chart/108873/3 "2017-11-23T15:40:16Z")

</div>

Hi Abhishek,

unfortunately you currently cannot divide the output of an aggregation.

If you actually are not drawing a "Count" aggregation, but e.g. an average, you could create a scripted field in the management section, that has the value of your desired field divided by 3 in it. If you now use this scripted field to calculate average or sum or etc. it will calculate against all values divided by 3, which will have the same effect. But if you are looking into dividing the actual "count" of documents by 3, that's not working in classical visualizations.

This can work in timelion (but that would require you want to draw data over time), by calling `.divide(3)` on your data function ([Timelion Tutorial](https://www.timroes.de/2017/08/02/timelion-tutorial-from-zero-to-hero/)).

Cheers,  
Tim

---

<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 21, 2017, 3:40pm UTC](https://discuss.elastic.co/t/dividing-value-of-chart/108873/4 "2017-12-21T15:40:25Z")

</div>

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