{"id":490,"date":"2015-05-18T09:48:14","date_gmt":"2015-05-17T23:48:14","guid":{"rendered":"http:\/\/x37v.com\/x37v\/?p=490"},"modified":"2022-02-02T20:04:07","modified_gmt":"2022-02-02T09:04:07","slug":"dict-object","status":"publish","type":"post","link":"https:\/\/x37v.com\/x37v\/max\/dict-object\/","title":{"rendered":"Structuring JSON data with the [dict] object in Max"},"content":{"rendered":"\n<div class=\"wp-block-group\"><div class=\"wp-block-group__inner-container is-layout-flow wp-block-group-is-layout-flow\">\n<pre class=\"wp-block-code\"><code lang=\"json\" class=\"language-json\">{\n\t\"perceivedComplexity\": \"beastly\",\n\t\"actualComplexity\": \"manageable\",\n}<\/code><\/pre>\n\n\n\n<p>Working with setting and getting content from <em>dictionaries<\/em> in Max seems straightforward enough, but trying to group data into well-structured form can be a little tricky.<\/p>\n<\/div><\/div>\n\n\n\n<h4 class=\"wp-block-heading\" id=\"structured-data\">Structured Data<\/h4>\n\n\n\n<p>Recently I had a need to create a way to store some fairly complex data in Max. I wanted to map out and find similarities in a bunch of audio files. I&#8217;m not a computer scientist or a real programmer, so I had no idea how I should do this or how I should store this information in a manageable way. [As it turns out, I needed to create a <em><a href=\"http:\/\/en.wikipedia.org\/wiki\/Hash_table\">hash table<\/a><\/em>.]<\/p>\n\n\n\n<p>Traditionally, the <code class=\"max object\" data-outlets=\"4\">coll<\/code> object was the <em>go-to<\/em> object to do this kind of stuff (and still is to an extent). It&#8217;s a simple way to store a list of values at a numerical (or symbolic) <em>index<\/em>.<\/p>\n\n\n\n<div class=\"wp-block-group\"><div class=\"wp-block-group__inner-container is-layout-flow wp-block-group-is-layout-flow\">\n<pre class=\"wp-block-code\"><code lang=\"properties\" class=\"language-properties\">1, 100 72 64 forward 7.43 delay 85 0;\n2, 60 160 62 forward 5.0 bypass 51 1;\n3, 82 10 114 backward 0.2 delay 15 1;\n4, 155 97 98 backward 8.2 delay 99 0;<\/code><\/pre>\n\n\n\n<p>Send the <code class=\"max object\" data-outlets=\"4\">coll<\/code> object a <code class=\"max message\">2<\/code>, and the corresponding data (<code class=\"max message\">60 160 62 forward 5.0 bypass 51 1<\/code>) will come out the first outlet.<\/p>\n<\/div><\/div>\n\n\n\n<p>When trying to encode lots of data though, a more descriptive <em>index<\/em> would be more helpful.<\/p>\n\n\n\n<p>While <code class=\"max object\" data-outlets=\"4\">coll<\/code> supports indexes that are symbols, I was keen to use something that allowed me to look up or retrieve particular &#8216;atoms&#8217; of the information I was storing. With <code class=\"max object\" data-outlets=\"4\">coll<\/code>, if you request the data stored at an index, you retrieve <em>all<\/em> the data stored at that index. As <code class=\"max object\" data-outlets=\"4\">coll<\/code> data is stored as a list of values, the order of the data stored at that index is important, and it can be a little difficult to see what each value represents. Furthermore, as I was interested in storing and retrieving data based on some kind of shared similarity (ie. separate arrays of data that should be grouped under the same &#8216;index&#8217;) I wanted to store it in a more descriptive and extensible way. What I needed was something like an <a href=\"http:\/\/en.wikipedia.org\/wiki\/Associative_array\">associative array<\/a>.<\/p>\n\n\n\n<p>Associative arrays store every piece of information as <em>key<\/em> and <em>value<\/em> pairs. This data structure goes by many differing names (dictionaries, hashes, maps, symbol tables, hash tables, collections). In the JavaScript world these kinds data storage structures are referred to as <a href=\"http:\/\/www.w3schools.com\/js\/js_objects.asp\">objects<\/a>. I&#8217;ll refer to them as <em>objects<\/em> for the time being. (Just to confuse things more, <em>key-value<\/em> pairs are also sometimes termed <em>name-value<\/em> pairs, <em>index-value<\/em> pairs, and <em><a href=\"http:\/\/en.wikipedia.org\/wiki\/Attribute\u2013value_pair\">attribute-value pairs<\/a><\/em>.)<\/p>\n\n\n\n<p>The <em>key<\/em> would describe the bit of information I was interested in storing, and the <em>value<\/em> would be the number\/setting\/value representing that information.<\/p>\n\n\n\n<p>Essentially, <em>objects<\/em> represent structured data like this:<\/p>\n\n\n\n<div class=\"wp-block-group\"><div class=\"wp-block-group__inner-container is-layout-flow wp-block-group-is-layout-flow\">\n<div class=\"wp-block-columns is-layout-flex wp-container-core-columns-is-layout-9d6595d7 wp-block-columns-is-layout-flex\">\n<div class=\"wp-block-column is-layout-flow wp-block-column-is-layout-flow\" style=\"flex-basis:100%\">\n<div class=\"wp-block-group\"><div class=\"wp-block-group__inner-container is-layout-flow wp-block-group-is-layout-flow\">\n<pre class=\"wp-block-code\"><code lang=\"json\" class=\"language-json\">{\n\t\"name\": \"Alex\",\n\t\"sex\": \"male\",\n\t\"age\": 35,\n\t\"coffee\": \"espresso\",\n\t\"coffeeTimes\": [7, 9, 11, 16]\n}<\/code><\/pre>\n\n\n\n<p>An example of <em>object notation<\/em>.<\/p>\n<\/div><\/div>\n<\/div>\n<\/div>\n<\/div><\/div>\n\n\n\n<p><em>key<\/em>s sit on the left, <em>value<\/em>s on the right. There&#8217;s a colon after each <em>key<\/em>, and a comma after the first to the penultimate <em>key-value<\/em> pair. <em>key<\/em>s are strings, and all strings are surrounded by quotes (eg. <code>\"coffee\"<\/code> or <code>\"espresso\"<\/code>), and arrays are a list of comma separated values in square brackets (eg. <code>[7, 8, 11, 16]<\/code>).<\/p>\n\n\n\n<p>The cool thing about <em>object notation<\/em> is that values can be strings, numbers, lists\/arrays, or <em>even objects themselves<\/em>. Even better is that you can insert a new <em>key-value<\/em> pair at any point within your object and it won&#8217;t break anything, because you retrieve <em>value<\/em>s by their <em>key<\/em> (in contrast to <code class=\"max object\" data-outlets=\"4\">coll<\/code> where you&#8217;d have to keep track of where the data value you were storing was in the array of values stored at that index).<\/p>\n\n\n\n<p>Combined with arrays, objects are very flexible ways to store and format data. <a href=\"http:\/\/alignedleft.com\/tutorials\/d3\/data-types\">Scott Murray&#8217;s D3 Tutorial chapter on Data Types<\/a> illustrates the power of objects and arrays really well: <q>&#8220;You can combine these two structures to create arrays of objects, or objects of arrays, or objects of objects or, well, basically whatever structure makes sense for your data set.&#8221;<\/q><\/p>\n\n\n\n<h4 class=\"wp-block-heading\" id=\"what-do-arrays-of-objects-objects-of-arrays-and-objects-of-objects-mean\">What do &#8216;arrays of objects&#8217;, &#8216;objects of arrays&#8217;, and &#8216;objects of objects&#8217; mean?<\/h4>\n\n\n\n<p>Well, many things. If an <em>array<\/em> is a list of items, and an <em>object<\/em> is a collection of named properties grouped together. You could combine them in ways to:<\/p>\n\n\n\n<ul class=\"wp-block-list\"><li>create a list of data structures that were all related in some way and assign them all to one <em>key<\/em>ed list (and access info about each one by its <em>index<\/em> in the array); or<\/li><li>nest specific bits of information within the context in which they are relevant; or<\/li><li>have a collection of properties that had their own groups of sub properties, and so on.<\/li><\/ul>\n\n\n\n<div class=\"wp-block-group\"><div class=\"wp-block-group__inner-container is-layout-flow wp-block-group-is-layout-flow\">\n<p>Example 1:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code lang=\"json\" class=\"language-json\">{\n\t\"animals\": [\n\t\t{ \"name\": \"Alex\", \"sex\": \"male\", \"age\": 35, \"species\": \"human\" },\n\t\t{ \"name\": \"Benny\", \"sex\": \"male\", \"age\": 3, \"species\": \"cat\" },\n\t\t{ \"name\": \"Mench\", \"sex\": \"male\", \"age\": 6, \"species\": \"cat\" }\t\t\n\t]\n}<\/code><\/pre>\n\n\n\n<p>The <em>animals<\/em> key contains an array of objects.<\/p>\n<\/div><\/div>\n\n\n\n<div class=\"wp-block-group\"><div class=\"wp-block-group__inner-container is-layout-flow wp-block-group-is-layout-flow\">\n<p>Example 2:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code lang=\"json\" class=\"language-json\">{\n\t\"series1\": [ 0, 1, 3, 7, 15, 31, 63 ],\n\t\"series2\": [ 1, 4, 9, 16, 25, 36, 49 ],\n\t\"series3\": [ 1, 2, 4, 7, 11, 16, 22 ],\n\t\"series4\": [ 1, 1, 2, 3, 5, 8, 13 ]\n}<\/code><\/pre>\n\n\n\n<p>An object whose <em>key<\/em>s are all arrays.<\/p>\n<\/div><\/div>\n\n\n\n<div class=\"wp-block-group\"><div class=\"wp-block-group__inner-container is-layout-flow wp-block-group-is-layout-flow\">\n<p>Example 3:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code lang=\"json\" class=\"language-json\">{\n\t\"name\": \"Alex\",\n\t\"sex\": \"male\",\n\t\"age\": 35,\n\t\"coffee\": {\n\t\t\"type\": \"espresso\",\n\t\t\"specs\": {\n\t\t\t\"shots\": 2,\n\t\t\t\"milk\": 1,\n\t\t\t\"sugar\": 0\n\t\t}\n\t},\n\t\"coffeeTimes\": [ 7, 9, 11, 16 ]\n}<\/code><\/pre>\n\n\n\n<p>Note that the &#8216;coffee&#8217; <em>key<\/em> contains an object with two keys (&#8216;type&#8217; and &#8216;specs&#8217;), and the value of &#8216;specs&#8217; itself is an object.<\/p>\n<\/div><\/div>\n\n\n\n<p>Essentially, <code>[]<\/code> indicates an array, and <code>{}<\/code> an object. In JavaScript, you access objects&#8217; <em>value<\/em>s by their <em>key<\/em>, and arrays&#8217; <em>value<\/em>s by appending their numerical <em>index<\/em> (starting at 0) in square brackets. If an object is contained within another object, you use &#8216;dot&#8217; notation to indicate the &#8216;path&#8217; to the desired named element.<\/p>\n\n\n\n<div class=\"wp-block-group\"><div class=\"wp-block-group__inner-container is-layout-flow wp-block-group-is-layout-flow\">\n<pre class=\"wp-block-code\"><code lang=\"javascript\" class=\"language-javascript\">age\t\t\t\t\t\/\/ Returns 35\ncoffee.type\t\t\t\/\/ Returns \"espresso\"\ncoffee.specs.shots\t\/\/ Returns 2\ncoffeeTimes[2]\t\t\/\/ Returns 11<\/code><\/pre>\n\n\n\n<p>Retrieving properties of keys and arrays in JavaScript.<\/p>\n<\/div><\/div>\n\n\n\n<h4 class=\"wp-block-heading\" id=\"javascript-object-notation\">JavaScript Object Notation<\/h4>\n\n\n\n<p>JavaScript Object Notation (or JSON) is a specific syntax for organising data as JavaScript objects. Essentially <em>keys<\/em> are wrapped in double quotes, as are the <em>values<\/em> if they are strings\/symbols.<\/p>\n\n\n\n<div class=\"wp-block-group\"><div class=\"wp-block-group__inner-container is-layout-flow wp-block-group-is-layout-flow\">\n<pre class=\"wp-block-code\"><code lang=\"json\" class=\"language-json\">{\n  \"firstName\": \"John\",\n  \"lastName\": \"Smith\",\n  \"isAlive\": true,\n  \"age\": 25,\n  \"address\": {\n    \"streetAddress\": \"21 2nd Street\",\n    \"city\": \"New York\",\n    \"state\": \"NY\",\n    \"postalCode\": \"10021-3100\"\n  },\n  \"phoneNumbers\": [\n    {\n      \"type\": \"home\",\n      \"number\": \"212 555-1234\"\n    },\n    {\n      \"type\": \"office\",\n      \"number\": \"646 555-4567\"\n    }\n  ],\n  \"children\": [],\n  \"spouse\": null\n}<\/code><\/pre>\n\n\n\n<p>[From the <a href=\"http:\/\/en.wikipedia.org\/wiki\/JSON\">JSON entry on Wikipedia<\/a><\/p>\n<\/div><\/div>\n\n\n\n<p>Note again that the <em>value<\/em> stored under &#8216;address&#8217; is itself an object that contains its own <em>key-value<\/em> pairs, and that &#8216;phoneNumbers&#8217; contains an <em>array of objects<\/em>.<\/p>\n\n\n\n<hr class=\"wp-block-separator\"\/>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"dictionaries-in-max-the-dict-object\"><em>Dictionaries<\/em> in Max: The [dict] object<\/h3>\n\n\n\n<p>The <a href=\"https:\/\/docs.cycling74.com\/max7\/maxobject\/dict\"><code class=\"max object\" data-inlets=\"2\" data-outlets=\"4\">dict<\/code><\/a> object <a href=\"https:\/\/www.youtube.com\/watch?v=zN14jVNdWWw\">emerged in Max 6<\/a> as a way to store structured data like this. As the term &#8216;object&#8217; in Max refers to elements within a patch that perform a function, <em>object-like data structures<\/em> are referred to as <strong>dictionaries<\/strong> in Max.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code lang=\"json\" class=\"language-json\">{\n\t\"key\": \"value\",\n\t\"anotherKey\": \"anotherValue\"\n}<\/code><\/pre>\n\n\n\n<h4 class=\"wp-block-heading\" id=\"why-are-dictionaries-good\">Why are dictionaries good?<\/h4>\n\n\n\n<p>Apart from the fact that data can be structured in a more meaningful and readable way, the order of the <em>key-value<\/em> data pairs they contain doesn&#8217;t matter. As alluded to above, in the <code class=\"max object\" data-outlets=\"4\">coll<\/code> object, changing the order of the values in an array would likely break something in your patch (as the position of the items in the array carries some kind of associative meaning), whereas in a dictionary the order doesn&#8217;t matter as you request the value stored at a <em>key<\/em> (as opposed to the <em>n<\/em>th item in a list).<\/p>\n\n\n\n<p>In a <code class=\"max object\" data-outlets=\"4\">coll<\/code>:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code lang=\"properties\" class=\"language-properties\">1, 100 72 64 forward 7.43 delay 85 0;<\/code><\/pre>\n\n\n\n<p>&#8230; is different to:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code lang=\"properties\" class=\"language-properties\">1, 64 forward 100 72 7.43 delay 85 0;<\/code><\/pre>\n\n\n\n<p>Whereas in a <code class=\"max object\" data-inlets=\"2\" data-outlets=\"4\">dict<\/code>:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code lang=\"json\" class=\"language-json\">{\n\t\"key1\": 54,\n\t\"key2\": 95,\n\t\"key3\": 8\n}<\/code><\/pre>\n\n\n\n<p>&#8230;is equivalent to:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code lang=\"json\" class=\"language-json\">{\n\t\"key1\": 54,\n\t\"key3\": 8,\n\t\"key2\": 95\n}<\/code><\/pre>\n\n\n\n<h4 class=\"wp-block-heading\" id=\"building-dictionary-content\">Building <em>dictionary<\/em> content<\/h4>\n\n\n\n<p>The <code class=\"max object\" data-inlets=\"2\" data-outlets=\"4\">dict<\/code> object allows us to programmatically build up content in a JSON-like way. There are a few ways of setting content in a <code class=\"max object\" data-inlets=\"2\" data-outlets=\"4\">dict<\/code> object.<\/p>\n\n\n\n<p><code class=\"max message\">set<\/code>, <code class=\"max message\">append<\/code>, and <code class=\"max message\">replace<\/code> messages allow you to:<\/p>\n\n\n\n<ul class=\"wp-block-list\"><li><code>set<\/code> a string (symbol), number (int\/float), or array at a particular key;<\/li><li><code>append<\/code> values to a specified key to turn it into an array (or insert the key and value pair if it does not existing within the dictionary); and<\/li><li><code>replace<\/code> the value at an existing key (or insert the key and value pair if it does not existing within the dictionary).<\/li><\/ul>\n\n\n\n<p>For example, the message:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\"><code class=\"max message\">set tree 4<\/code><\/pre>\n\n\n\n<p>Creates the following in the <code class=\"max object\" data-inlets=\"2\" data-outlets=\"4\">dict<\/code>:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code lang=\"json\" class=\"language-json\">{\n\t\"tree\": 4\n}<\/code><\/pre>\n\n\n\n<p>\u2026and sending the message: <span style=\"opacity: 0.5\">(if the <code class=\"max object\" data-inlets=\"2\" data-outlets=\"4\">dict<\/code> already contained <code>{\"tree\": 4}<\/code>)<\/span><\/p>\n\n\n\n<pre class=\"wp-block-preformatted\"><code class=\"max message\">append tree oak<\/code><\/pre>\n\n\n\n<p>\u2026\u00a0would result in:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code lang=\"json\" class=\"language-json\">{\n\t\"tree\": [4, \"oak\"]\n}<\/code><\/pre>\n\n\n\n<p>(We&#8217;ve appended a value to the key &#8216;tree&#8217;, so it now contains an array of two items.)<\/p>\n\n\n\n<p>Message:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\"><code class=\"max message\">replace tree none<\/code><\/pre>\n\n\n\n<p>\u2026\u00a0changes <code class=\"max object\" data-inlets=\"2\" data-outlets=\"4\">dict<\/code>&#8216;s content to:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code lang=\"json\" class=\"language-json\"><code>{\n\t\"tree\": \"none\"\n}<\/code><\/code><\/pre>\n\n\n\n<p>(Replace the value at key &#8216;tree&#8217; with something else.)<\/p>\n\n\n\n<p>Before we get to nesting dictionaries within dictionaries, let&#8217;s look at how to retrieve content.<\/p>\n\n\n\n<h4 class=\"wp-block-heading\" id=\"retrieving-content-from-a-dictionary\">Retrieving content from a dictionary<\/h4>\n\n\n\n<pre class=\"wp-block-code\"><code lang=\"json\" class=\"language-json\">{\n\t\"name\": \"Alex\",\n\t\"sex\": \"male\",\n\t\"age\": 35,\n\t\"coffee\": {\n\t\t\"type\": \"espresso\",\n\t\t\"specs\": {\n\t\t\t\"shots\": 2,\n\t\t\t\"milk\": 1,\n\t\t\t\"sugar\": 0\n\t\t}\n\t},\n\t\"coffeeTimes\": [ 7, 9, 11, 16 ]\n}\n<\/code><\/pre>\n\n\n\n<p>There are a few methods that allow you to get information from a dictionary: <code class=\"max message\">get<\/code>, <code class=\"max message\">gettype<\/code>, <code class=\"max message\">getsize<\/code>, and <code class=\"max message\">getkeys<\/code>. Given the dictionary above, the following is an example of what gets output with these <em>get<\/em> methods.<\/p>\n\n\n\n<table>\n<tbody><tr>\n<th style=\"text-align: left;\">Method<\/th>\n<th style=\"text-align: left;\">Example key<\/th>\n<th style=\"text-align: left;\">Output (key and value)<\/th>\n<\/tr>\n<tr>\n<td rowspan=\"5\" style=\"vertical-align: top;\">get<\/td>\n<td>name<\/td>\n<td>name Alex<\/td>\n<\/tr>\n<tr>\n<td>sex<\/td>\n<td>sex male<\/td>\n<\/tr>\n<tr>\n<td>coffee<\/td>\n<td>coffee dictionary u504001192<\/td>\n<\/tr>\n<tr>\n<td>coffee::type<\/td>\n<td>coffee::type espresso<\/td>\n<\/tr>\n<tr>\n<td>coffeeTimes<\/td>\n<td>coffeeTimes 7 9 11 16<\/td>\n<\/tr>\n<tr>\n<td rowspan=\"4\" style=\"vertical-align: top;\">gettype<\/td>\n<td>name<\/td>\n<td>symbol<\/td>\n<\/tr>\n<tr>\n<td>age<\/td>\n<td>int<\/td>\n<\/tr>\n<tr>\n<td>coffee<\/td>\n<td>coffee dictionary<\/td>\n<\/tr>\n<tr>\n<td>coffeetimes<\/td>\n<td>coffeeTimes array<\/td>\n<\/tr>\n<tr>\n<td rowspan=\"5\" style=\"vertical-align: top;\">getsize<\/td>\n<td>name<\/td>\n<td>name 1 [ie. 1 string]<\/td>\n<\/tr>\n<tr>\n<td>age<\/td>\n<td>age 1 [ie. 1 int]<\/td>\n<\/tr>\n<tr>\n<td>coffee<\/td>\n<td>coffee 1 [ie. 1 dictionary]<\/td>\n<\/tr>\n<tr>\n<td>coffee::specs<\/td>\n<td>coffee::specs 1 [ie. 1 dictionary]<\/td>\n<\/tr>\n<tr>\n<td>coffeeTimes<\/td>\n<td>coffeeTimes 4 [ie. 4 values in the array]<\/td>\n<\/tr>\n<tr>\n<td>getkeys<\/td>\n<td colspan=\"2\">[outputs a list of all the top level keys]<\/td>\n<\/tr>\n<\/tbody><\/table>\n\n\n\n<p>Note that to access nested dictionary content (eg. &#8216;specs&#8217;), you use a double colon separator (::) \u2014&nbsp;ie. <code class=\"max message\">get coffee::type<\/code>.<\/p>\n\n\n\n<h4 class=\"wp-block-heading\" id=\"so-we-can-retrieve-nested-dictionary-content-but-how-do-we-set-it\">So we can retrieve <em>nested<\/em> dictionary content, but how do we set it?<\/h4>\n\n\n\n<p>Setting key-value pairs is easy, but setting <em>nested<\/em> dictionary content (ie. a dictionary at a key, or an array of dictionaries at a key) requires a few little steps to do correctly. Let&#8217;s build a complex set of nested content like <a href=\"http:\/\/geojson.org\/geojson-spec.html\">GeoJSON data<\/a> as an example:<\/p>\n\n\n\n<div class=\"wp-block-group\"><div class=\"wp-block-group__inner-container is-layout-flow wp-block-group-is-layout-flow\">\n<pre class=\"wp-block-code\"><code lang=\"json\" class=\"language-json\">{\n    \"type\": \"FeatureCollection\",\n    \"features\": [\n        {\n            \"type\": \"Feature\",\n            \"geometry\": {\n                \"type\": \"Point\",\n                \"coordinates\": [ 150.1282427, -24.471803 ]\n            },\n            \"properties\": {\n                \"type\": \"town\"\n            }\n        }\n    ]\n}<\/code><\/pre>\n\n\n\n<p>[From Scott Murray&#8217;s <a href=\"http:\/\/alignedleft.com\/tutorials\/d3\/data-types\">Types of data<\/a>]<\/p>\n<\/div><\/div>\n\n\n\n<h4 class=\"wp-block-heading\" id=\"the-setparse-message\">The <em>setparse<\/em> message<\/h4>\n\n\n\n<p>There&#8217;s not very much about <code class=\"max message\">setparse<\/code> in the Max help patches, but <code class=\"max message\">setparse<\/code> is one of the most important messages when trying to construct dictionaries within dictionaries using Max messages.<\/p>\n\n\n\n<p><code class=\"max message\">setparse<\/code> allows you to set content as a <em>dictionary<\/em> at a specified key.<\/p>\n\n\n\n<p>Let&#8217;s go back to a simple example:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code lang=\"json\" class=\"language-json\">{\n\t\"name\": \"Alex\",\n\t\"sex\": \"male\",\n\t\"age\": 35\n}<\/code><\/pre>\n\n\n\n<p>The syntax for <code class=\"max message\">setparse<\/code> goes like this:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\"><code class=\"max message\">setparse coffee type: espresso<\/code><\/pre>\n\n\n\n<p>The first word after &#8216;setparse&#8217; is the <em>key<\/em> at which you wish to add some dictionary value. If the second word has a trailing colon (eg. as in &#8216;type:&#8217;), it creates a <strong>dictionary<\/strong> with that key (&#8216;type&#8217;) within the first key (&#8216;coffee&#8217;). Re-read that if it didn&#8217;t make sense.<\/p>\n\n\n\n<p>If you list a value after the second word (eg. &#8216;espresso&#8217;), it sets the value at the second word&#8217;s <em>key<\/em> (ie. the <em>value<\/em> of the nested dictionary&#8217;s <em>key<\/em>).<\/p>\n\n\n\n<p>Namely, the dictionary would now look like this:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code lang=\"json\" class=\"language-json\">{\n\t\"name\": \"Alex\",\n\t\"sex\": \"male\",\n\t\"age\": 35,\n\t\"coffee\": {\n\t\t\"type\": \"espresso\"\n\t}\n}<\/code><\/pre>\n\n\n\n<p>You can specify as many words with trailing colons as you like and it will create those keys, eg. the message:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\"><code class=\"max message\">setparse coffee origin: roast: age:<\/code><\/pre>\n\n\n\n<p>&#8230;would create:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code lang=\"json\" class=\"language-json\">{\n\t\"name\": \"Alex\",\n\t\"sex\": \"male\",\n\t\"age\": 35,\n\t\"coffee\": {\n\t\t\"origin\": \"*\",\n\t\t\"roast\": \"*\",\n\t\t\"age\": \"*\"\n\t}\n}<\/code><\/pre>\n\n\n\n<p>&#8230;and Max will store placeholder text (<code>\"*\"<\/code>) at those keys (if no value is listed after each key). Note though that the <code>type<\/code> key disappeared. When you <code>set<\/code> content (and this includes <code>setparse<\/code>), it <em>overwrites<\/em> existing content at that key. It is sometimes best to create a <em>key<\/em> with <code>setparse<\/code>:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code lang=\"json\" class=\"language-json\">{\n\t\"name\": \"Alex\",\n\t\"sex\": \"male\",\n\t\"age\": 35\n}<\/code><\/pre>\n\n\n\n<pre class=\"wp-block-preformatted\"><code class=\"max message\">setparse coffee type: espresso<\/code><\/pre>\n\n\n\n<p>&#8230; then <em>append<\/em> the elements one at a time like this:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\"><code class=\"max message\">append coffee::origin *<\/code>\n<code class=\"max message\">append coffee::roast *<\/code>\n<code class=\"max message\">append coffee::age *<\/code><\/pre>\n\n\n\n<p>This will retain the four keys (<code>type:<\/code>, <code>origin:<\/code>, <code>roast:<\/code>, and <code>age:<\/code>)<\/p>\n\n\n\n<h4 class=\"wp-block-heading\" id=\"making-a-key-store-an-array-of-dictionaries\">Making a <em>key<\/em> store an <em>array of dictionaries<\/em>.<\/h4>\n\n\n\n<p>Lastly, if you want an item stored at a <em>key<\/em> to be an <em>array of dictionaries<\/em>, there is a cool thing you can do to achieve this (that, as far as I can see is undocumented in the help patches).<\/p>\n\n\n\n<p>Let&#8217;s try to create this structure:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code lang=\"json\" class=\"language-json\">{\n    \"type\": \"FeatureCollection\",\n    \"features\": [\n        {\n            \"type\": \"Feature\",\n            \"geometry\": {\n                \"type\": \"Point\",\n                \"coordinates\": [ 150.1282427, -24.471803 ]\n            },\n            \"properties\": {\n                \"type\": \"town\"\n            }\n        }\n    ]\n}<\/code><\/pre>\n\n\n\n<p>Here is a list of messages (with a comment explaining what each does):<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\"><code class=\"max message\">set type FeatureCollection<\/code> \/\/ <code class=\"max comment bubble\" data-arrow=\"left\">create a key called 'type' and assign it the value 'FeatureCollection'<\/code>\n<code class=\"max message\">set features<\/code> \/\/ <code class=\"max comment bubble\" data-arrow=\"left\">create an 'empty key' called 'features'<\/code>\n<code class=\"max message\">append features<\/code> \/\/ <code class=\"max comment bubble\" data-arrow=\"left\">this is a crucial step - this turns features' value into an empty array<\/code>\n<code class=\"max message\">setparse features[0] type: geometry: properties:<\/code> \/\/ <code class=\"max comment bubble\" data-arrow=\"left\">creates an object with three keys under the first 'features' key of the array<\/code>\n<code class=\"max message\">set features[0]::type Feature<\/code> \/\/ <code class=\"max comment bubble\" data-arrow=\"left\">as with the last step, we need to ensure we address the items with square bracket notation now that it's an array<\/code>\n\n\n<code class=\"max message\">setparse features[0]::geometry type: coordinates:<\/code> \/\/ <code class=\"max comment bubble\" data-arrow=\"left\">add a key with a dictionary value (with its own two keys) to 'features'<\/code>\n<code class=\"max message\">set features[0]::geometry::type Point<\/code> \/\/ <code class=\"max comment bubble\" data-arrow=\"left\">set the value of 'type' within the geometry dictionary<\/code>\n<code class=\"max message\">set features[0]::geometry::coordinates 150.12825 -24.471804<\/code> \/\/ <code class=\"max comment bubble\" data-arrow=\"left\">set the value of 'coordinates' within the geometry dictionary to an array of floats<\/code>\n\n\n<code class=\"max message\">setparse features[0]::geometry type: Point coordinates: 150.12825 -24.471804<\/code> \/\/ <code class=\"max comment bubble\" data-arrow=\"left\">or the previous 3 lines all in one step<\/code>\n\n<code class=\"max message\">setparse features[0]::properties type: town<\/code> \/\/ <code class=\"max comment bubble\" data-arrow=\"left\">create a new key 'properties' and set its content as a dictionary<\/code><\/pre>\n\n\n\n<p>Optional: should you wish to extend the length of the &#8216;features&#8217; array, try:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\"><code class=\"max message\">append features *<\/code> \/\/ <code class=\"max comment bubble\" data-arrow=\"left\">append some dummy data to the 'features' array, then...<\/code>\n<code class=\"max message\">setparse features[1] type: geometry: properties:<\/code> \/\/ <code class=\"max comment bubble\" data-arrow=\"left\">add the keys<\/code>\n<code class=\"max message\">append features *<\/code> \/\/ <code class=\"max comment bubble\" data-arrow=\"left\">again, extend the 'features' array<\/code>\n<code class=\"max message\">setparse features[2] type: geometry: properties:<\/code> \/\/ <code class=\"max comment bubble\" data-arrow=\"left\">add keys to the third item in the array<\/code>\n<code class=\"max message\">append features *<\/code> \/\/ <code class=\"max comment bubble\" data-arrow=\"left\">and again, extend the 'features' array<\/code>\n<code class=\"max message\">setparse features[3] type: geometry: properties:<\/code> \/\/ <code class=\"max comment bubble\" data-arrow=\"left\">...you get the idea.<\/code>\n<\/pre>\n\n\n\n<h4 class=\"wp-block-heading\" id=\"building-geojson-data-example-patch\"><em>Building GeoJSON data<\/em> example patch<\/h4>\n\n\n\n<p>A comprehensive tutorial (aside from <a href=\"https:\/\/docs.cycling74.com\/max7\/vignettes\/dictionaries\">this vignette<\/a>) from Cycling &#8217;74 is still very much desired, but in the meantime check out the help patch below for some examples of how to create complex dictionary structures.<\/p>\n\n\n<div id=\"dictobject-link-490\" class=\"dictobject-link sh-hide\"><a href=\"#\" onclick=\"showhide_toggle('dictobject', 490, 'Show Patch', 'Hide Patch'); return false;\"><span id=\"dictobject-toggle-490\">Show Patch<\/span><\/a><\/div><div id=\"dictobject-content-490\" class=\"dictobject-content sh-hide\" style=\"display: none;\"><\/p>\n<pre><code>\n----------begin_max5_patcher----------\n4511.3oc6cslabiiD921mBh9ONYfSGQp2d90frX.1E6NyBrCv9ij.C4Vzs0D\n0RMjXaGOAAHGh8.jcOJyQImjkjEU2RcqW1Vu5Yb.hsapGMqOVrphEqp3mN8j\nYWE+QZ5LzEn2hN4jOc5ImHaRzvIpOexrUdebQnWp71lshll5sjN6b3ZL5GYx\n1Snqhukhtl5w1jvekpqGsYUPTHkIeXxtFi2vxZEqZEZhc+ZJzelMC8d0kV6w\nVbSPzxKS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VfxXz.JY4C\nPZtzfAIfiZHZ50BI58Njr1KIshxvlLeku.vETNdoKpkYprxLc+AmpZ8qNT2j\nwP8oWHGtT3jLFv4NCjU.pvH3ghOS4iShd8Rk0l.7Y44vFrogp5ssMtN3wc3Q\nGElrUDEZGWzP.NF4bSopbfUE3XOvRskxpUqOdvPBXANXqZYSzGTK6FJZGrk2\nsdabvCGSvPQ2fY710x66z+jcd18cNWZvX7cxWh3q.E5HCbevwO2Sc4ZYmeMG\nTEPJqNO7DIt8qcEcy1LC9lP4gXcsJL6gzqqytjRQQaXKqL3Gan7STyvoEo7J\nOQYGeLkbRb2xPQ8fpLQMUXhBARpr6TrTI.v99AsqB7qOE9ZSUQnjHi7f3y8.\nlf11ablT8F6IUuwZR0aJVCBdfcGstu6Lo5M5SpgphYvSEcGxv0evsYVtwfMX\ngmVSywVSJVYrwzBclVSsvjoU2AOs5NZSqtSaDC9HmXA1gwWM8szjT0qT1Q3l\n69qwIhOJ2l4YbaXgOJeiyRn2Fjc+x8MclWB2RTF2bQgqHjAKgCrVnYqh8oIQ\naBjnyohu4Oe5+G39xomL\n-----------end_max5_patcher-----------\n<\/code><\/pre>\n<p><\/div>\n","protected":false},"excerpt":{"rendered":"<p>Working with setting and getting content from dictionaries in Max seems straightforward enough, but trying to group data into well-structured form can be a little tricky. Structured Data Recently I had a need to create a way to store some fairly complex data in Max. I wanted to map out and find similarities in a [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"jetpack_post_was_ever_published":false,"_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_jetpack_memberships_contains_paid_content":false,"footnotes":"","jetpack_publicize_message":"","jetpack_publicize_feature_enabled":true,"jetpack_social_post_already_shared":true,"jetpack_social_options":{"image_generator_settings":{"template":"highway","enabled":false},"version":2}},"categories":[13],"tags":[],"class_list":["post-490","post","type-post","status-publish","format-standard","hentry","category-max"],"jetpack_publicize_connections":[],"jetpack_featured_media_url":"","jetpack_sharing_enabled":true,"jetpack_shortlink":"https:\/\/wp.me\/p4SgL0-7U","_links":{"self":[{"href":"https:\/\/x37v.com\/x37v\/wp-json\/wp\/v2\/posts\/490","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/x37v.com\/x37v\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/x37v.com\/x37v\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/x37v.com\/x37v\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/x37v.com\/x37v\/wp-json\/wp\/v2\/comments?post=490"}],"version-history":[{"count":46,"href":"https:\/\/x37v.com\/x37v\/wp-json\/wp\/v2\/posts\/490\/revisions"}],"predecessor-version":[{"id":723,"href":"https:\/\/x37v.com\/x37v\/wp-json\/wp\/v2\/posts\/490\/revisions\/723"}],"wp:attachment":[{"href":"https:\/\/x37v.com\/x37v\/wp-json\/wp\/v2\/media?parent=490"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/x37v.com\/x37v\/wp-json\/wp\/v2\/categories?post=490"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/x37v.com\/x37v\/wp-json\/wp\/v2\/tags?post=490"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}