Vertical Bar Chart - different vaue for each bar

Hey,

I'm currently trying to display six different values in a single vertical bar chart, but I want a seperate bar for each value.

To make it more clear, I have 6 values a,b,c,x,y and z. Each has a string that should be displayed at the x axis and a number (double).

This should be possible or not? If I add a y metric it gets added on the same bar and it is hard to compare them on the first view.

Attached is a (badly made) image of what I want to go for.

The values have the timestamp and are supposed to change over time

I made it with six seperate bar charts so far, but there should be a better way right?

Thanks in advance!

edit: Ok having six bar charts is not an option, it slows down my dashboard so much that instead of refreshing every second it is more like every 7-10 seconds (I have three other visualizations aside the bar chart)

Hi @Kamran_Samaie,

you can get the effect you're looking for by applying the "Terms" aggregation twice, once to define the x-axis categories and once to get Kibana to assign individual sub-category colors to each term:

I accidentally cut off the x-axis labels in that screenshot, but they are there :wink:.

I tried that, but it didn't work for me since I don't want to display count or anyting, but the last value that has been uploaded.

I changed the way I upload and instead of uploading all values together I upload them one by one and visualize the last six values that I got.

But even with with one instead of six charts the auto refresh doesn't work smoothly...
I made a metric chart showing the last value of a scripted field containing doc['@timestamp'].date.secondOfDay so I can see if the refresh rate is accurate and unfortunately it is not at all...

Displaying the last value(s) sounds like a job for the "Top Hits" aggregation, which was introduced in Kibana 5.3.

The performance problems you are describing indicate that your Elasticsearch cluster might lack resources for the amount of data you are processing. Or the network connection between Elasticsearch, Kibana and the browser is too slow. Or any number of other reasons related to the environment you're running Elasticsearch and Kibana in could cause that. The search profiler released in Version 5.1.1 of X-Pack might be able to help you diagnosing this. It is available in the free license tier.

Yeah I used the "Top Hits" aggregation for my solution as well, but I can only take it for the y-axis, but not as the aggregation for the split bars. Therefore it didn't work?

This is what I get when I upload everything at the same time

and this is what I get if I upload the values one by one and display the last six

Regarding the performance issues

I reduced the amount of data I upload as much as possible, so basically I upload six strings and six numbers every second, so I doubt it should be too much, right?
For the network connection, I'm currently still working on my local machine, therefore I ruled that factor out as well.

I'll try the search profiler and give an update if I come to any conclusion

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