Visulizing the count of words in a pdf

i found here
that term aggregation return the count of the number of document where the word exists notnot the total number of words across those documents.
so is there a way to made a visulastion on the total number of words ??