Create value on missing time series

Hello everyone ;),

This my use case :slight_smile:

Is it possible with elasticsearch to create missing value on a time series with a query ?
For example, I have a series of data per hour with one value missing hour 5.

2017-04-10 00:00 584
2017-04-10 01:00 410
2017-04-10 02:00 988
2017-04-10 03:00 488
2017-04-10 04:00 19
XXXXXXXXXXXXXXXXXXXXXXXX <= this data not exist
2017-04-10 06:00 85
2017-04-10 07:00 564

for the hour 5, I would like repeat the last value or calculate the value with average of the X last values or others calculations for example.

thanks

Hey,

you have to come up with something like that yourself (using a date histogram aggregation to find empty buckets, and then create those artificial documents with whatever value you want them to be - the last point is exactly the reason why there is no such mechanism, everyone would need an own one anyway very likely).

--Alex

thanks

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.