I've got an es-index with metrics (like sessions, clicks and so on) and would like to compute a clickthrough rate in different date ranges.
I have seen that Kibana has a feature called scripted fields. But they are doing formula stuff like
doc['clicks'].sum() / doc['pageviews'].sum() * 100
only inside a single doc.
Is there a way to compute metrics in a range of docs? I've heard that timelion has got a feature like this but I would like to get a table as a visualisation result.