Kibana words histogram

Hi ,

I have indexed several documents with several fields in ES and I am using Kibana to visualize it. One of them is text that is analyzed.

I would like to be able to get a histogram with the counts of the words, so not only being able to count in how many documents each of the words appears, but also how many times in total.

So say that the field with the text is this, and we have 2 documents:

text:{i am tired today today tired}
text:{today i have to work}

i would get a graph where i see that today=3, tired=2 etc etc.


I can't think of a way to do this in Kibana UI. The Terms aggregation returns only the number of documents that contain a given word, not the total number of words across those documents. In Elasticsearch itself, the Term Vectors API has a terms statistics option that will return total term frequencies across all documents:

You can use the Kibana Sense plugin to easily interact with ES APIs, if you haven't done it before:

1 Like

Thanks for the answer, I will try that.