Make Object Invisible Before Scene Loads

How can I make a material invisible in my shapespark model before the scene loads. I would like a material to start off with visible = false so that I can later change it to visible = true through the javascript API.

Material objects have opacity property that you could use for this purpose:

material.opacity = 0;
viewer.requestFrame();
...
material.opacity = 1;
viewer.requestFrame();