How to perform data binning in DolphinDB?

15 Views Asked by At

I want to bin data by equal width and equal frequency, which can be achieved by using functions qcut or cut in Python. How to achieve this in DolphinDB?

1

There are 1 best solutions below

0
Claire mcc On

Equal width binning divides data into intervals with equal width but the data volume of each bin varies. In DolphinDB, you can use the bucket function.

Equal frequency binning divides data evenly into intervals with equal data volume. In DolphinDB, you can use the rank function to specify the groupNum or use the bar function to specify the interval.