Calculate Mode and Median

is there any way to calculate Mode and Median of a field?

I’ve seen that there is the Stat extension available but it only calculates variance and standard deviation.

Does anyone already calculate it (even in javascript eventually)?



You can actually do approximate medians and percentiles using the approximate histogram extension.
Refer to docs here -