# Creating Graph For All Documents In ES

**URL:** <https://discuss.elastic.co/t/creating-graph-for-all-documents-in-es/181411>\
**Category:** Kibana\
**Created:** [May 16, 2019, 1:47pm UTC](https://discuss.elastic.co/t/creating-graph-for-all-documents-in-es/181411 "2019-05-16T13:47:13Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![irfancnk](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/irfancnk/32/60249_2.png) [@irfancnk](https://discuss.elastic.co/u/irfancnk)\
**Post date:** [May 16, 2019, 1:47pm UTC](https://discuss.elastic.co/t/creating-graph-for-all-documents-in-es/181411/1 "2019-05-16T13:47:13Z")

</div>

Hi there,

In elastic-search I store a data structure like following 🙂

```
{ 
     "source": "192.168.0.113", 
     "destination": "108.177.127.138", 
     "timestamp": 1558011580.284477000, 
     "sent_timestamp": 1558011577.509367, 
     "time_diff": 2.77511, 
     "type": "UDP"

```

}

My purpose is to store network packets like TCP, UDP, SNMP etc.  
Each packet has a timestamp and sent\_timestamp. Is it possible to sort packets with respect to their timestamps in the X-Axis, and show the time\_diff in the Y axis. If so, what is the aggregation types in the Y and X axis? Is there such a filtering for creating graphs for an attribute of document?  
At the end, I need something that looks like the following.

![ques](https://us1.discourse-cdn.com/elastic/original/3X/8/5/8568a8bd06167c7971c32aeed625cd7220ba3104.png)

---

<div class="post-metadata">

**Author:** ![thomasneirynck](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/thomasneirynck/32/23313_2.png) [@thomasneirynck](https://discuss.elastic.co/u/thomasneirynck)\
**Post date:** [May 16, 2019, 2:09pm UTC](https://discuss.elastic.co/t/creating-graph-for-all-documents-in-es/181411/2 "2019-05-16T14:09:37Z")

</div>

@irfancnk

to show individual documents on a graph, you could use a Vega-vizualization.

this blog post might get you started [https://www.timroes.de/kibana-vega-scatterplot](https://www.timroes.de/kibana-vega-scatterplot)

---

<div class="post-metadata">

**Author:** ![irfancnk](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/irfancnk/32/60249_2.png) [@irfancnk](https://discuss.elastic.co/u/irfancnk)\
**Post date:** [May 16, 2019, 2:26pm UTC](https://discuss.elastic.co/t/creating-graph-for-all-documents-in-es/181411/3 "2019-05-16T14:26:49Z")

</div>

That helped a lot, thank you so much 😀

---

<div class="post-metadata">

**Author:** ![irfancnk](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/irfancnk/32/60249_2.png) [@irfancnk](https://discuss.elastic.co/u/irfancnk)\
**Post date:** [May 16, 2019, 2:46pm UTC](https://discuss.elastic.co/t/creating-graph-for-all-documents-in-es/181411/4 "2019-05-16T14:46:28Z")

</div>

By the way, is The Vega Visualization only way for creating graphs with individual documents?

---

<div class="post-metadata">

**Author:** ![thomasneirynck](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/thomasneirynck/32/23313_2.png) [@thomasneirynck](https://discuss.elastic.co/u/thomasneirynck)\
**Post date:** [May 16, 2019, 3:38pm UTC](https://discuss.elastic.co/t/creating-graph-for-all-documents-in-es/181411/5 "2019-05-16T15:38:04Z")

</div>

yes, broadly, but there's a few other places as well

- You can show a saved-search with individual documents as a table on a dashboard. create this in Discover
- the Maps-app allows you to map individual documents as well

---

<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:** [June 13, 2019, 3:38pm UTC](https://discuss.elastic.co/t/creating-graph-for-all-documents-in-es/181411/6 "2019-06-13T15:38:05Z")

</div>

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