try assignSG as a command, it doesnt work unless you have already assigned a shader to a piece of geomtery. I tried looking for help on it but it doesnt even exist in the documentatino but if you turn on "Echo All Commands" in the script editor it's there and maya uses it to assign the shading group. So once you've assigned something it will work (but there's still no help for it!)Maybe I'm doing it wrong, but I tried "maya" as a command, but it also says it does not exist?