If you want to make scripts that manipulate nodes in your scene, you will need to use the real names of the attributes for your nodes as understood by the Harmony scripting interface. For example, to refer to the position of a peg node on the (x) axis, you would need to refer to the real name of the corresponding attribute in your script, which is position.x.
You can easily obtain the real names of a node's attributes by exposing them in the Layer Properties dialog. To do this, you must enable Publish Attribute Mode. On top of allowing you to add certain attributes in a node to the list of attributes in its parent group's properties, Publish Attribute Mode also displays the name of each attribute as understood by the Harmony scripting interface.