Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

6
  • $\begingroup$ Nice job. You gave the answer I was going to give and showed me a new function. :-) $\endgroup$ Commented Jul 24, 2014 at 13:17
  • 1
    $\begingroup$ Thanks a lot. I was trying to figure out how to get Replace to work like that but I was thinking in terms of the /. syntax and it never occurred to me that it would have level specs. There seems to be no mention of the GeneralUtilities` package in the Help Browser, as far as I can tell ? $\endgroup$ Commented Jul 25, 2014 at 7:30
  • $\begingroup$ @JohnJowett Yes, it is undocumented at present. $\endgroup$ Commented Jul 25, 2014 at 10:21
  • $\begingroup$ ToAssociations do not work for lists with RuleDelayed, I used you second method as Replace[rdata, x : {__RuleDelayed | __Rule} :> Association[x], {0, Infinity}]. Tks! +1 $\endgroup$ Commented Oct 29, 2014 at 19:25
  • 1
    $\begingroup$ This is now also available as ResourceFunction["ToAssociations"] $\endgroup$ Commented Apr 30, 2019 at 17:46