Auto-Binner Numbering

I generated 10 bins. The bins names are text. Then I sort bins Bin 10 is the next to  Bin 1.

Is it possible add leading spaces or zeroes to proper allow bin sorting?

Thank you


Hi Izaychik63,

Since the Bins are text, they are sorted as text and you get Bin 10 next to Bin 1.

You could allow numeric sorting in two steps.

  1. Remove "Bin " from the column with String Replace or String Manipulation nodes;
  2. Convert column with bins to number with String to Number node.

Attached is a small workflow to help you.


Bins.knwf (6.3 KB)

I used Regex Split with .*(.\d) to get correct numbering.
Anyway, to assume additional operations after Auto-Binner sounds odd.

You can also use the option “Use Midpoint” than you can afterwards change this into a numerical column and sort it?

Cheers, Iris