question: @ Override public void execute ( MetricTimeSeries timeSeries , FunctionValueMap functionValueMap ) { if ( timeSeries . isEmpty ( ) ) { return ; } timeSeries . sort ( ) ; LongList timeList = new LongList ( timeSeries . size ( ) ) ; DoubleList valueList = new DoubleList ( timeSeries . size ( ) ) ; Set < Double > distinct = new HashSet < > ( ) ; for ( int i = 0 ; i < timeSeries . size ( ) ; i ++ ) { double value = timeSeries . getValue ( i ) ; if ( ! distinct . contains ( value ) ) { timeList . add ( timeSeries . getTime ( i ) ) ; valueList . add ( value ) ; distinct . add ( value ) ; } } timeSeries . clear ( ) ; timeSeries . addAll ( timeList , valueList ) ; functionValueMap . add ( this ) ; }
target:  Transforms a time series into a representation with distinct values. The distinct operation uses the first occurrence of a point.