How can I show the value of a specific field from the most recent document in a time frame

I have an ingest of logs where 1 field gets updated each time. Let say every minute I receive a logline and the count field holds certain value.
In Kibana I can select for example the last hour as timeframe. Now I would like to show the value of the count field of the last logged line. (i.e the last document stored in elastic). How can I do this?