# Date histogram and JSON imput

**URL:** <https://discuss.elastic.co/t/date-histogram-and-json-imput/189555>\
**Category:** Kibana\
**Created:** [July 9, 2019, 1:09pm UTC](https://discuss.elastic.co/t/date-histogram-and-json-imput/189555 "2019-07-09T13:09:16Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Vitorsc23](https://avatars.discourse-cdn.com/v4/letter/v/958977/32.png) [@Vitorsc23](https://discuss.elastic.co/u/Vitorsc23)\
**Post date:** [July 9, 2019, 1:09pm UTC](https://discuss.elastic.co/t/date-histogram-and-json-imput/189555/1 "2019-07-09T13:09:16Z")

</div>

Hi, I am on Kibana 7.2. I would like to show the average of some field for the last 24 months, but when I put this ![image](https://us1.discourse-cdn.com/elastic/original/3X/3/2/328a9c18d58cf8621b15accf454e139a817689de.png). It aggregate on 730 days and show the average of it. But I want the avarege individually per month for the last 24 months. Could I do it on the field JSON imput? And I would more docs about this field.

---

<div class="post-metadata">

**Author:** ![Marius\_Dragomir](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/marius_dragomir/32/42087_2.png) [@Marius\_Dragomir](https://discuss.elastic.co/u/Marius_Dragomir)\
**Post date:** [July 12, 2019, 9:50am UTC](https://discuss.elastic.co/t/date-histogram-and-json-imput/189555/2 "2019-07-12T09:50:49Z")

</div>

You should change the interval to 1M and then in the timpicker (top right) select "Last 24 months". This way you can see the average individually per month, for the last 24 months.

---

<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:** [August 9, 2019, 9:50am UTC](https://discuss.elastic.co/t/date-histogram-and-json-imput/189555/3 "2019-08-09T09:50:53Z")

</div>

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