Skip to content

Resample aggregation functions give inconsistent results for floting point data #6741

@chbuescher

Description

@chbuescher

I'm trying to use the resampling aggregation functions avgResample, anyResample .. for downscaling time series metric data. When there is no data in the interval for downsampling, the resample results depend on the used aggregation function.
For example avgResample gives nan values but minResamples gives 0

select avgResample(10,20,2)(value, number) from (select number, rand()/4294967296 as value from numbers(10))

avgResample(10, 20, 2)(value, number)
[nan,nan,nan,nan,nan]

minResample(10, 20, 2)(value, number)
[0,0,0,0,0]                           │

IMHO when downsampling floating point data the resample function should return nan values in this case.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions