tabfind-help.pd 1.9 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455
  1. #N canvas 1 53 510 378 10;
  2. #X obj 0 299 table pig;
  3. #X obj 94 138 tabfind pig;
  4. #X obj -3 24 f;
  5. #X obj -3 7 bng 15 250 50 0 empty empty empty 17 7 0 10 -4034 -257985
  6. -1;
  7. #X msg 89 116 set wig;
  8. #X obj 64 299 table wig;
  9. #X msg 70 97 set pig;
  10. #X msg 0 266 \; wig 0 88 89 88 83 22 0 11;
  11. #X msg 51 78 nth \$1;
  12. #X text 107 61 By default tabfind finds the first instance of the input.
  13. ;
  14. #X text 98 77 The [nth( message sets which instance to fnd.;
  15. #X obj 55 194 loadbang;
  16. #X text 131 96 The [set( message sets which array to look in.;
  17. #X text 148 159 index \, or length of array if input not found.;
  18. #X msg 16 43 76 72 71;
  19. #X msg 45 221 \; pig 0 72 73 75 76 72 71 72 76 88 0 0 99 100 101 102
  20. 76 72 71 99 98 97;
  21. #X text 281 297 2008_11_20 Martin Peach;
  22. #X obj 51 62 nbx 5 14 1 1e+37 0 1 empty empty empty 0 -8 0 10 -4034
  23. -16662 -1 1 256;
  24. #X obj 17 7 nbx 3 14 -1e+37 1e+37 0 1 empty empty empty 0 -8 0 10 -4034
  25. -16662 -1 99 256;
  26. #X obj 94 160 nbx 5 14 -1e+37 1e+37 0 0 empty empty empty 0 -8 0 10
  27. -4032 -258113 -1 0 256;
  28. #X text -4 -30 [tabfind] searches an array and outputs the index at
  29. which the input float or list of floats is found.;
  30. #X text 166 137 argument is the name of the array to search in.;
  31. #X text 55 6 <--find this number.;
  32. #X text 71 43 <-- or find this sequence.;
  33. #N canvas 434 305 494 344 META 0;
  34. #X text 12 135 HELP_PATCH_AUTHORS "pd meta" information added by Jonathan
  35. Wilkes for Pd version 0.42.;
  36. #X text 12 25 LICENSE GPL v2 or later;
  37. #X text 12 115 AUTHOR Martin Peach;
  38. #X text 12 5 KEYWORDS control array;
  39. #X text 12 46 DESCRIPTION search an array and output the index at which
  40. the input float or list of floats is found;
  41. #X text 12 75 INLET_0 float list nth set;
  42. #X text 12 95 OUTLET_0 float;
  43. #X restore 444 310 pd META;
  44. #X connect 1 0 19 0;
  45. #X connect 2 0 1 0;
  46. #X connect 3 0 2 0;
  47. #X connect 4 0 1 0;
  48. #X connect 6 0 1 0;
  49. #X connect 8 0 1 0;
  50. #X connect 11 0 15 0;
  51. #X connect 11 0 7 0;
  52. #X connect 14 0 1 0;
  53. #X connect 17 0 8 0;
  54. #X connect 18 0 2 1;