Display Rate Metric

I would like to create a Kibana visualization that displays a single metric that is the count (or sum) divided by the time interval given by the time filter (hence showing the average rate for the time period).

This seems simple but I can't see a way to achieve this currently.

I understand that this could be related to pipeline aggregation, but it seems like it should be simple to do in Kibana even without pipeline aggregations.

Timelion has this functionality, but it is currently not available for Kibana visualisations.