hi folks, is there any easy and straightforward way to find what is the index, on a table, of some value? Like by sending to some object its value?
thanks alex
With [tabdump] (from zexy) and [list-find] (from list-abs), it should be possible. ++
Jack
Le jeudi 10 juin 2010 à 00:40 -0400, Alexandre Porres a écrit :
hi folks, is there any easy and straightforward way to find what is the index, on a table, of some value? Like by sending to some object its value?
thanks alex _______________________________________________ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management -> http://lists.puredata.info/listinfo/pd-list
My tabletool extern does this. There's an [equals( function that returns the number of occurrences of a value and their indices.
http://williambrent.conflations.com/pages/research.html#tabletool
On Wed, Jun 9, 2010 at 9:40 PM, Alexandre Porres porres@gmail.com wrote:
hi folks, is there any easy and straightforward way to find what is the index, on a table, of some value? Like by sending to some object its value? thanks alex _______________________________________________ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management -> http://lists.puredata.info/listinfo/pd-list
On Thu, 10 Jun 2010, Alexandre Porres wrote:
hi folks, is there any easy and straightforward way to find what is the index, on a table, of some value? Like by sending to some object its value?
[listfind] from GridFlow does it from a list.
It doesn't contain an optimisation specifically for sorted lists, though.
You can make an abstraction that does it with a sorted list or table in O(log n) time by recursive binary partitioning.
_ _ __ ___ _____ ________ _____________ _____________________ ... | Mathieu Bouchard, Montréal, Québec. téléphone: +1.514.383.3801