I looked in the python api and there is indeed a way to do this, but still some scripting required. It can be installed by looking at the documentation page I mentioned earlier.
If you want to actually move the nodes onto the grid after spacing them you could write some more code, or just select all the nodes and drag them to the grid with the cursor. The default grid size is 2x1, and can be changed by doing what I mentioned in my previous response. You will of course need to disable the default layout hotkey.
import hou
from canvaseventtypes import *
import nodegraphdisplay as display
import nodegraphview as view
def action(uievent):
if isinstance(uievent, KeyboardEvent) and uievent.eventtype == 'keyhit':
editor = uievent.editor
node = editor.currentNode()
parent = node.parent()
key = uievent.key
step_x = 2
step_y = 1
if key == "A":
parent.layoutChildren(horizontal_spacing=step_x, vertical_spacing=step_y)