Trying to standardize a range values in a list to a few values rather than every number being slightly different

Hi, I have a range of numbers generated from the graph mapper and I would like to standardize them into a few discrete varieties but still have the same list length.

I’d like to be able to make a slider that goes from 1-5 that would simplify the values in the list in to a smaller variety numbers. So for a list of 100 items, if I picked “4” on the slider then each of those numbers would be 25, 50, 75 or 100.

This is the actual list I’m working with at the moment:

I apologize for what must be a commonplace question. There must be a correct search term for this but everything I search for is different than what I’m trying to get. If there’s a better search term or a few ways that this is often done, I’d like to pointed in the right direction. (9.7 KB)

1 Like

Thanks @martinsiegrist - you gave me the first step of what I’m trying to do.

Next I need to replace each of those 100 numbers with either 25, 50, 75 or 100 based on whichever is closest. This is because I need to pass that value to each of the 100 items on the other sided of the list.

Kept searching and found it on a dynamo forum:

As it turns out Find Similar Member is the component that does the job of replacing the numbers that were narrowed down using the range.

This is what ended up working:

1 Like