Percentage of docs which contain keyword in array field

Thanks @Bill_McConaghy, that was a helpful link. After a lot of messing around I was able to get the stats I was after.

I'll give some feedback for others that might run into these issues as well as the Kibana devs for improvements.

The value to be calculated for me seemed completely trivial, I simply wanted the doc count of a filter (for a specific term in a field) over the total doc count. The filter_ratio was the way to go, but it took a lot of time messing around with the interval and the global time filter before I got the values I was expecting. I needed to use the Overall Average as Lee suggested in the linked thread, but even using that it still didn't give sensible values. All my docs had times within the last 90 days, but when changing the global time filter from 1 year to 2 or 5 years the values would change. I think it's not entirely obvious how this value is being calculated.

For the record, the way I set it up to get correct values was to explicitly set the interval in the Panel Options to '1y' (and NOT auto) and to set the global time filter to last 1 year (if I set it to 'this year' I get 0 values for some reason).

I think it's silly that the whole process requires such sensitive fine tuning for what I would assume is the most obvious value to be calculating for this ratio.

Screenshots: