#N canvas 479 53 560 496 10;
#X obj 3 247 cnv 3 550 3 empty empty inlets 8 12 0 13 #dcdcdc #000000 0;
#X obj 3 367 cnv 3 550 3 empty empty outlets 8 12 0 13 #dcdcdc #000000 0;
#X obj 3 439 cnv 3 550 3 empty empty attributes 8 12 0 13 #dcdcdc #000000 0;
#X obj 86 255 cnv 17 3 86 empty empty 0 5 9 0 16 #dcdcdc #9c9c9c 0;
#X obj 86 376 cnv 17 3 17 empty empty 0 5 9 0 16 #dcdcdc #9c9c9c 0;
#X obj 86 345 cnv 17 3 17 empty empty 1 5 9 0 16 #dcdcdc #9c9c9c 0;
#X obj 3 470 cnv 15 552 21 empty empty empty 20 12 0 14 #e0e0e0 #202020 0;
#X text 159 254 -;
#X text 129 254 bang;
#X text 159 280 -;
#X text 122 280 float;
#X text 159 307 -;
#X text 128 307 list;
#X text 159 326 -;
#X text 174 326 see:;
#X text 159 346 -;
#X text 122 346 float;
#X text 159 377 -;
#X text 122 377 float;
#X obj 261 146 nbx 5 14 -1e+37 1e+37 0 0 empty empty empty 0 -8 0 10 #dcdcdc #000000 #000000 0 256;
#X obj 186 145 nbx 5 14 -1e+37 1e+37 0 0 empty empty empty 0 -8 0 10 #dcdcdc #000000 #000000 0 256;
#X obj 186 220 nbx 5 14 -1e+37 1e+37 0 0 empty empty empty 0 -8 0 10 #dcdcdc #000000 #000000 0 256;
#N canvas 570 98 640 610 All_Messages 0;
#X text 145 48 outputs the stored numbers on the left outlet, f 78;
#X text 96 4 clear -;
#X text 145 5 sets all values to 0, f 78;
#X text 48 18 const <float> -;
#X text 90 32 cancel -;
#X text 102 48 dump -;
#X text 24 91 fquantile <float> -;
#X text 54 156 goto <float> -;
#X text 102 202 load -;
#X text 90 186 length -;
#X text 145 185 outputs the table size, f 78;
#X text 145 236 retrieves the maximum stored value, f 78;
#X text 106 236 max -;
#X text 106 252 min -;
#X text 145 252 retrieves the minimum stored value, f 78;
#X text 102 283 next -;
#X text 90 309 normal -;
#X text 102 325 open -;
#X text 145 325 opens the editor window (same as double-clicking on it), f 78;
#X text 102 341 prev -;
#X text 145 563 closes the editing window, f 78;
#X text 107 548 sum -;
#X text 89 563 wclose -;
#X text 95 578 write -;
#X text 145 578 opens a standard save file dialog for saving it in a text file format, f 78;
#X text 145 548 outputs the sum of all values, f 78;
#X text 48 391 read <symbol> -;
#X text 41 486 setbits <list> -;
#X text 145 19 fills the table with the given number, f 78;
#X text 42 119 getbits <list> -;
#X text 145 156 sets a pointer to the address specified by the number, f 78;
#X text 60 171 inv <float> -;
#X text 145 392 opens and reads data from a file specified by the symbol. If no symbol is given \, an open dialog is shown, f 78;
#X text 41 418 refer <symbol> -;
#X text 5 433 send <symbol \, float> -;
#X text 145 433 sends the value stored at the address specified by the float to all [receive] objects with the symbol name name, f 78;
#X text 145 459 the first float specifies a starting address and the next numbers specify the values to be stored from that address on, f 78;
#X text 65 459 set <list> -;
#X text 145 485 changes a stored number's bit values: 1st float is the address \, 2nd is the starting bit location (0-31 from LSB to MSB) \, 3rd is how many from starting bit should be modified and 4th is the value (in decimal or hexadecimal form) to which those bits should be set, f 78;
#X text 145 33 cancels last right inlet input (so next left input outputs a number), f 78;
#X text 145 119 1st float is the address to query \, 2nd is starting bit location (0-31 from LSB to MSB) and 3rd is how many bits to the right of starting bit should be sent (as a single decimal integer), f 78;
#X text 145 283 sends the value stored at the pointed address on left outlet and sets the pointer to the next address (wraps to 1st address when reaching the end), f 78;
#X text 145 340 similar to "next" message \, but the decreases the pointer address (and wraps to last address when reaching start), f 78;
#X text 145 533 sets the number of values in the table (default: 128 \, indexed from 0 to 127), f 78;
#X text 145 418 sets the object to read from a named table specified by the symbol, f 78;
#X text 48 267 name <symbol> -;
#X text 53 533 size <float> -;
#X text 48 63 embed <float> -;
#X text 145 63 1 toggles saving the data as part of the patch - default 0 (don't save), f 78;
#X text 54 77 flags <f \, f> -;
#X text 145 78 <1 \, 0> saves contents with the patch when it's saved \, <0 \, 1> doesn't, f 78;
#X text 145 93 sends the address at which the sum of all values up to that address is >= to the the sum of all table values times the <float> (between 0 and 1), f 78;
#X text 145 366 sends the address at which the sum of the all values up to that address is >= the the sum of all table values times the <int> divided by 2^15 (32768), f 78;
#X text 42 366 quantile <int> -;
#X text 145 200 sets to load mode: all numbers received in the left inlet are stored beginning at address 0 until the end (additional numbers are ignored) or taken out of load mode by a normal message., f 78;
#X text 145 309 changes from "load mode" to "normal" mode (see "load message"), f 78;
#X text 145 267 sets a table name and is the same as "refer", f 78;
#X text 145 171 finds the first table value which is >= the float and sends its address, f 78;
#X restore 201 326 pd All_Messages;
#N canvas 836 207 417 233 name 0;
#X text 201 173 <= from Pd Vanilla;
#X text 33 136 And still create the vanilla object from vanilla without namespaces as:;
#X text 34 17 Pd also has a vanilla object named [table]. Cyclone avoids name clashing and overwriting an internal in Pd Vanilla \, but for that you need to use the cyclone namespace ("cyclone/" before the object name) \, as it's the common practice for cyclone's documentation. So you create it as:;
#X obj 151 98 cyclone/table;
#C restore;
#X obj 165 173 table;
#X restore 460 222 pd name clash;
#X obj 3 400 cnv 3 550 3 empty empty arguments 8 12 0 13 #dcdcdc #000000 0;
#X text 159 407 -;
#X text 98 407 1) symbol;
#X text 174 346 sets value (y) to be stored at the index sent to left inlet, f 61;
#X text 174 307 a pair of index (x) and its value (y): sets "y" to "x", f 61;
#X text 104 326 messages;
#X text 61 83 [table] stores and edits a number array. You can graphically edit it by opening it or double clicking on it. There are also several message methods \, check it below., f 65;
#N canvas 864 211 350 179 examples 0;
#N canvas 708 23 454 597 load/normal 0;
#X obj 109 286 bng 15 250 50 0 empty empty empty 17 7 0 10 #dcdcdc #000000 #000000;
#X text 132 286 <= populate the table with random values;
#X obj 109 357 random 1000;
#X obj 109 332 cyclone/uzi 128;
#X text 26 17 The [table] object has two modes of operation for loading values into it. The default is the "normal" mode \, where it expects a "y" value in the right inlet and an index "x" in the left inlet.;
#X obj 144 166 cyclone/table;
#C restore;
#X obj 71 86 bng 15 250 50 0 empty empty empty 17 7 0 10 #dcdcdc #000000 #000000;
#X text 94 86 <= populate the table with random values;
#X obj 71 112 cyclone/uzi 128 0;
#X obj 219 134 random 1000;
#X obj 170 133 t f b;
#X obj 208 387 cyclone/table;
#C restore;
#X msg 208 357 load;
#X obj 109 309 trigger bang bang;
#X text 32 203 If you send it a "load" message \, the object goes into "load" mode \, where numbers in the left inlet are stored from index 0 to the end of the table. If more numbers than available indexes are given \, then they're ignored. For you to populate the table again you need to first send the "load" message again.;
#X text 49 436 The "normal" message sets it back to the normal mode of operation.;
#X obj 209 522 cyclone/table;
#C restore;
#X obj 284 499 nbx 5 14 -1e+37 1e+37 0 0 empty empty empty 0 -8 0 10 #dcdcdc #000000 #000000 0 256;
#X obj 209 498 nbx 5 14 -1e+37 1e+37 0 0 empty empty empty 0 -8 0 10 #dcdcdc #000000 #000000 0 256;
#X obj 209 549 nbx 5 14 -1e+37 1e+37 0 0 empty empty empty 0 -8 0 10 #dcdcdc #000000 #000000 0 256;
#X msg 189 473 normal;
#X msg 149 473 load;
#X connect 0 0 13 0;
#X connect 2 0 11 0;
#X connect 3 0 2 0;
#X connect 6 0 8 0;
#X connect 8 2 10 0;
#X connect 9 0 5 1;
#X connect 10 0 5 0;
#X connect 10 1 9 0;
#X connect 12 0 11 0;
#X connect 13 0 3 0;
#X connect 13 1 12 0;
#X connect 16 0 19 0;
#X connect 17 0 16 1;
#X connect 18 0 16 0;
#X connect 20 0 16 0;
#X connect 21 0 16 0;
#X restore 118 61 pd load/normal modes;
#N canvas 435 199 831 484 argument/attributes 0;
#X obj 89 277 cyclone/table x;
#C restore;
#X text 119 103 <= populate the table from 0-127;
#X obj 63 129 cyclone/uzi 128 0;
#X obj 162 153 trigger f f;
#X obj 162 183 cyclone/table x;
#C restore;
#X msg 89 249 open;
#X obj 63 103 loadbang;
#X text 124 251 <= see that it shares the same values;
#X text 15 15 The [table] object takes an optional table name argument. If two or more [table] objects share the same name \, then they also share the same values. Below we have two objects named "x" \, the first one is populated with values. Open the other one and see that it shares the same values.;
#X obj 69 413 cyclone/table @name x;
#C restore;
#X obj 236 438 cyclone/table;
#C restore;
#X msg 236 407 name x;
#X obj 236 378 loadbang;
#X text 20 328 There is also a @name attribute that also sets a table name. You can also use the "name" message to set a table name.;
#X obj 516 150 cyclone/table @size 16;
#C restore;
#X msg 516 111 length;
#X obj 516 84 loadbang;
#X obj 516 181 nbx 4 14 -1e+37 1e+37 0 0 empty empty empty 0 -8 0 10 #dcdcdc #000000 #000000 0 256;
#X msg 586 120 size \$1;
#X obj 586 95 nbx 4 14 -1e+37 1e+37 0 0 empty empty empty 0 -8 0 10 #dcdcdc #000000 #000000 0 256;
#X text 415 23 You can set the table size with the "@size" attribute \, and also change the size afterwards with the size message.;
#X obj 523 426 cyclone/table @embed 1;
#C size 128;
#C flags 1 0 0 0;
#C tabrange 2;
#C _coords 0 0 0 0 0;
#C set 0 566 593 807 985 309 646 961 575 559 89 168 691 365 579 885 291 151 994 190 916 454 411 13 176 656 94 371 234 721 476 606 290 925 146 616 68 597 830 90 293 845 379 743 187 298 751 548 941 835 996 976 209 324 241 224 587 352 673 453 100 962 525 22 684 387 58 721 672 784 548 7 280 967 270 237 87 144 480 904 523 652 403 868 352 686 214 596 157 40 23 391 823 835 863 630 24 262 669 994 704 305 266 709 564 485 352 775 546 590 483 200 316 411 56 240 748 475 295 628 413 779 236 809 57 526 709 177 89;
#C restore;
#X msg 520 311 embed \$1;
#X obj 520 285 tgl 16 0 empty empty empty 17 7 0 10 #dcdcdc #000000 #000000 0 1;
#X text 417 221 The embed method/attribute saves the contents of the table with the patch. Note that the patch needs to be saved for the contents to be stored.;
#X obj 520 345 cyclone/table;
#C restore;
#X text 427 383 Click and open the edit window below and see that this table object has its contents stored.;
#X connect 2 2 3 0;
#X connect 3 0 4 0;
#X connect 3 1 4 1;
#X connect 5 0 0 0;
#X connect 6 0 2 0;
#X connect 11 0 10 0;
#X connect 12 0 11 0;
#X connect 14 0 17 0;
#X connect 15 0 14 0;
#X connect 16 0 15 0;
#X connect 18 0 14 0;
#X connect 19 0 18 0;
#X connect 22 0 25 0;
#X connect 23 0 22 0;
#X restore 118 85 pd argument/attributes;
#N canvas 428 43 550 603 basic_examples 0;
#X msg 190 164 const 23;
#X text 248 164 <= populate the table with a constant value, f 21;
#X msg 196 197 clear;
#X text 236 197 <= sets all values to 0;
#X msg 163 110 set 10 1 2 3 4 5;
#X text 269 110 <= sets values from index 10;
#X msg 178 133 4 3;
#X text 207 133 <= set value 3 to index 4;
#X obj 145 284 cyclone/table;
#C restore;
#X msg 107 72 open;
#X msg 146 72 wclose;
#X text 191 72 open/close editing window;
#X msg 73 42 read table-ex.txt;
#X obj 73 19 loadbang;
#X msg 29 42 write;
#X text 190 36 read/write can load and save files with contents of the table. If no file name is given \, a dialog window opens;
#X msg 215 239 dump;
#X text 247 238 <= dump all values from the table, f 18;
#X obj 145 312 print dump;
#X msg 183 461 cancel;
#X obj 206 522 cyclone/table;
#C restore;
#X obj 281 490 nbx 5 14 -1e+37 1e+37 0 0 empty empty empty 0 -8 0 10 #dcdcdc #000000 #000000 0 256;
#X obj 206 489 nbx 5 14 -1e+37 1e+37 0 0 empty empty empty 0 -8 0 10 #dcdcdc #000000 #000000 0 256;
#X obj 206 549 nbx 5 14 -1e+37 1e+37 0 0 empty empty empty 0 -8 0 10 #dcdcdc #000000 #000000 0 256;
#X text 45 347 If no value is given in the right inlet \, the left input gives you the value from the specified index. But if a value has been previously set in the right inlet \, then the left input stores that value at the given index., f 70;
#X text 45 402 Now \, if a value is given in the right inlet \, you can use the "cancel" message to make it "forget" \, so when you give it an index in the left inlet \, it only outputs its current value and doesn't store anything., f 70;
#X connect 0 0 8 0;
#X connect 2 0 8 0;
#X connect 4 0 8 0;
#X connect 6 0 8 0;
#X connect 8 0 18 0;
#X connect 9 0 8 0;
#X connect 10 0 8 0;
#X connect 12 0 8 0;
#X connect 13 0 12 0;
#X connect 14 0 8 0;
#X connect 16 0 8 0;
#X connect 19 0 20 0;
#X connect 20 0 23 0;
#X connect 21 0 20 1;
#X connect 22 0 20 0;
#X restore 118 39 pd basic_examples;
#N canvas 450 98 782 429 more_examples 0;
#X obj 60 300 nbx 5 14 -1e+37 1e+37 0 0 empty empty empty 0 -8 0 10 #dcdcdc #000000 #000000 0 256;
#X msg 93 203 sum;
#X msg 29 38 goto 50;
#X msg 42 63 next;
#X msg 60 87 prev;
#X msg 92 171 length;
#X msg 75 119 max;
#X msg 85 140 min;
#X text 84 38 go to index 50;
#X text 77 61 go to the next index and output its value;
#X text 95 86 go to the previous index and output its value;
#X text 105 118 output maximum value from the table;
#X text 113 139 output minimum value from the table;
#X text 138 171 output table's length;
#X text 120 202 output the sum of all table's avlues;
#X obj 60 271 cyclone/table;
#C restore;
#X msg 427 191 fquantile \$1;
#X obj 430 148 hsl 128 15 0 1 0 0 empty empty empty -2 -8 0 10 #dcdcdc #000000 #000000 0 1;
#X obj 427 170 nbx 5 14 -1e+37 1e+37 0 0 empty empty empty 0 -8 0 10 #dcdcdc #000000 #000000 0 256;
#X msg 407 115 quantile \$1;
#X obj 407 70 random 32768;
#X obj 407 46 bng 15 250 50 0 empty empty empty 17 7 0 10 #dcdcdc #000000 #000000;
#X obj 407 94 nbx 5 14 -1e+37 1e+37 0 0 empty empty empty 0 -8 0 10 #dcdcdc #000000 #000000 0 256;
#X obj 376 21 bng 15 250 50 0 empty empty empty 17 7 0 10 #dcdcdc #000000 #000000;
#X obj 407 313 nbx 5 14 -1e+37 1e+37 0 0 empty empty empty 0 -8 0 10 #dcdcdc #000000 #000000 0 256;
#X obj 407 285 cyclone/table;
#C restore;
#X text 487 88 sends the address at which the sum of the all values up to that address is >= the the sum of all table values times the input divided by 2^15 (32768), f 40;
#X text 514 176 same as quantile \, but the input range is a float from 0 to 1, f 35;
#X msg 443 248 inv \$1;
#X obj 443 227 nbx 4 14 -1e+37 1e+37 0 0 empty empty empty 0 -8 0 10 #dcdcdc #000000 #000000 0 256;
#X text 495 232 finds the first table value which is >= the input and sends its address, f 37;
#X text 395 20 same as below (random values from 0 to 32768 + quantile);
#X text 429 45 random + quantile;
#X msg 102 235 send x 3;
#X obj 270 255 receive x;
#X floatatom 270 280 5 0 0 0 - - - 0;
#X text 160 234 send value of index 3 to "x";
#X msg 142 361 refer x;
#X obj 142 388 cyclone/table;
#C restore;
#X text 198 360 <= the refer message loads contents from another table object with that name, f 77;
#X connect 1 0 15 0;
#X connect 2 0 15 0;
#X connect 3 0 15 0;
#X connect 4 0 15 0;
#X connect 5 0 15 0;
#X connect 6 0 15 0;
#X connect 7 0 15 0;
#X connect 15 0 0 0;
#X connect 16 0 25 0;
#X connect 17 0 18 0;
#X connect 18 0 16 0;
#X connect 19 0 25 0;
#X connect 20 0 22 0;
#X connect 21 0 20 0;
#X connect 22 0 19 0;
#X connect 23 0 25 0;
#X connect 25 0 24 0;
#X connect 28 0 25 0;
#X connect 29 0 28 0;
#X connect 33 0 15 0;
#X connect 34 0 35 0;
#X connect 37 0 38 0;
#X restore 118 108 pd more_examples;
#X restore 472 181 pd examples;
#X text 318 136 value stored at the index received in the left inlet, f 22;
#X text 62 134 index to output its value or store from right inlet value, f 19;
#X text 174 254 same as the quantile message with a random number between 0 and 32768 as an argument (see quantile in [pd All_Messages]), f 61;
#X text 174 280 index (x): outputs its value or stores the value from the right inlet (if given) at that index, f 61;
#X text 174 377 index values or else depending on the given message, f 62;
#X text 172 407 sets table name - if two or more [table] objects share the same name \, they also share the same values (default: none), f 61;
#X text 102 448 @size <float> (default 128) | @name <symbol> | @embed <float> (default 0), f 73;
#X obj 186 194 cyclone/table;
#C size 128;
#C flags 1 0 0 0;
#C tabrange 2;
#C _coords 0 0 0 0 0;
#C set 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0;
#C restore;
#N canvas 701 352 450 281 inconsistencies 0;
#X text 68 44 Note that [cyclone/table] has inconsistencies to the original Max object. In cyclone the edit window is not a graph \, but a list of numbers., f 55;
#X text 68 130 This makes attributes like @range \, @Signed & @notename not relevsant \, so they are missing. The @parameter sttribute also seems pointless in Pd., f 55;
#X text 68 176 The get/setbits messages are not actually implemented in cyclone yet \, but it seems to be buggy in Max anyway.;
#X text 68 85 This makes attributes like @range \, @signed & @notename not relevsant \, so they are missing. The @parameter sttribute also seems pointless in Pd., f 55;
#X restore 430 202 pd inconsistencies;
#X text 81 193 click to open =>;
#X obj 4 4 ./header table;
#X text 26 58 Store and edit a number array;
#X connect 19 0 39 1;
#X connect 20 0 39 0;
#X connect 39 0 21 0;
