Forums > MaxMSP

Is there a Max object to find the mathematical mode of several given values?

November 17, 2012 | 1:18 am

I looked all over the forums and couldn’t find anything about this.
Thanks to anyone who can assist me!

- Rob


November 17, 2012 | 8:19 am

I sure don’t guarantee that this is the easiest way, but it’s one way that came to mind.

– Pasted Max Patch, click to expand. –


ak
November 17, 2012 | 10:29 pm

just a simple algo patched with max objects. Versions for list of ints and floats. Not as elegant as Christopher solution (and almost surely less efficient), but it’s a good thing to have an alternative (esp. for floats). If there are many modes the least one is returned.

In the long run it’s better to write this in some js/java/c or pray to Cycling for extension of zl obj. family :).

– Pasted Max Patch, click to expand. –

November 17, 2012 | 11:26 pm

Thanks you all! You’ve been a huge help!


Viewing 4 posts - 1 through 4 (of 4 total)