# Use dates in the Y-axis

**URL:** <https://discuss.elastic.co/t/use-dates-in-the-y-axis/102733>\
**Category:** Kibana\
**Created:** [October 4, 2017, 4:10pm UTC](https://discuss.elastic.co/t/use-dates-in-the-y-axis/102733 "2017-10-04T16:10:43Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![Charlotte31](https://avatars.discourse-cdn.com/v4/letter/c/2bfe46/32.png) [@Charlotte31](https://discuss.elastic.co/u/Charlotte31)\
**Post date:** [October 4, 2017, 4:10pm UTC](https://discuss.elastic.co/t/use-dates-in-the-y-axis/102733/1 "2017-10-04T16:10:43Z")

</div>

Hello all,

I hope that I don't make a mistake and that the topic is not opened somewhere.

I want to use dates in Y-axis, and add the start time (in HH:mm:ss format) and the end time (same format) to show the tendency of batch in this axis.  
These fields are in date format, not number.

On the X-axis, it's just a date histogram by day.

I don't know what kind of aggregation I need to use (Max and Min are the only choices that allow me to show time, but it's completely wrong.

Could you help me ?

Regards,  
Charlotte

---

<div class="post-metadata">

**Author:** ![lukas](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/lukas/32/6812_2.png) [@lukas](https://discuss.elastic.co/u/lukas)\
**Post date:** [October 4, 2017, 5:52pm UTC](https://discuss.elastic.co/t/use-dates-in-the-y-axis/102733/2 "2017-10-04T17:52:42Z")

</div>

Could you provide a sample of your documents as well as some sort of sketch or screenshot of what you're trying to accomplish?

---

<div class="post-metadata">

**Author:** ![Charlotte31](https://avatars.discourse-cdn.com/v4/letter/c/2bfe46/32.png) [@Charlotte31](https://discuss.elastic.co/u/Charlotte31)\
**Post date:** [October 5, 2017, 7:50am UTC](https://discuss.elastic.co/t/use-dates-in-the-y-axis/102733/3 "2017-10-05T07:50:33Z")

</div>

I have this kind of data in my discover part :

 ![Discover_Y-axis dates](https://us1.discourse-cdn.com/elastic/original/3X/0/5/05618d31a006cf443d9dd26f2d206659e62c2942.PNG)

I want to use the EndTimeBatch and the StartTimeBatch in my Y-axis, and in the X-axis, the standard date histogram by day.

At final, the graph looks like that :

 ![Discover_Y-axis dates Batch Endtime and start time](https://us1.discourse-cdn.com/elastic/original/3X/0/f/0f8557f56cd2c396a17780028d8953971da33706.PNG)

But I don't find how to use date in the Y-axis.

I hope my answer is more clear.

Regards,  
Charlotte

---

<div class="post-metadata">

**Author:** ![lukas](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/lukas/32/6812_2.png) [@lukas](https://discuss.elastic.co/u/lukas)\
**Post date:** [October 9, 2017, 10:59pm UTC](https://discuss.elastic.co/t/use-dates-in-the-y-axis/102733/4 "2017-10-09T22:59:10Z")

</div>

What type do you have mapped for StartTimeBatch and EndTimeBatch?

---

<div class="post-metadata">

**Author:** ![cperriot](https://avatars.discourse-cdn.com/v4/letter/c/f475e1/32.png) [@cperriot](https://discuss.elastic.co/u/cperriot)\
**Post date:** [October 11, 2017, 7:30am UTC](https://discuss.elastic.co/t/use-dates-in-the-y-axis/102733/5 "2017-10-11T07:30:28Z")

</div>

Hello I have the exact same need. I want to check the tendencies of our nightly batches. I guess I could transform the time part of my @timestamps into a number of seconds since midnight but it won't be really readable.  
any idea ?  
thank you.

---

<div class="post-metadata">

**Author:** ![Charlotte31](https://avatars.discourse-cdn.com/v4/letter/c/2bfe46/32.png) [@Charlotte31](https://discuss.elastic.co/u/Charlotte31)\
**Post date:** [October 11, 2017, 9:08am UTC](https://discuss.elastic.co/t/use-dates-in-the-y-axis/102733/6 "2017-10-11T09:08:59Z")

</div>

The type of StartTimeBatch and EndTimeBatch is "date".  
I thought to transform in seconds, into a number format, but the legend of the Y-axis is not easily readable (you have seconds, not HH:mm:ss).

Maybe it's possible to transform on this format with the JSON Input in the advances option.

Regards,  
Charlotte

---

<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:** [November 8, 2017, 9:09am UTC](https://discuss.elastic.co/t/use-dates-in-the-y-axis/102733/7 "2017-11-08T09:09:02Z")

</div>

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