I do need to setup an association in Mathematica, in which the value of a key is a function of the value of another key (of the same association-object). Currently I am putting a dummy value at when the Association is created and then, with a further operation, change the dummy variable to the correct value.
I would really do that directly during the declaration. Any trick for that?
SS = Association[n -> 1.0, x -> 2, dummy -> 0]
SS["dummy"] = 100*SS[[Key[n]]] + SS[[Key[x]]]
Edit: If you insist on a "one-liner":
or even