wuwenw commented on pull request #6875: URL: https://github.com/apache/incubator-pinot/pull/6875#issuecomment-832356902
> Is this same as standard order statistics algorithm which gives worst case linear time (compared to heap sort approach) for selecting k largest or smallest elements? The selection algorithm used here is [quickselct](https://en.wikipedia.org/wiki/Quickselect#Time_complexity), a partial quicksort algorithm. The best case and average performance is O(n) but the worst case is O(n^2). -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org For additional commands, e-mail: commits-h...@pinot.apache.org