Dynamic rupture calculations using heterogeneous stress drop that is random and self-similar with a power-law spatial spectrum have great promise of producing realistic ground-motion predictions. We present procedures to specify initial stress for random events with a target rupture length and target magnitude. The stress function is modified in the depth dimension to account for the brittle-ductile transition at the base of the seismogenic zone. Self-similar fluctuations in stress drop are tied in this work to the long-wavelength stress variation that determines rupture length. Heterogeneous stress is related to friction levels in order to relate the model to physical concepts. In a variant of the model, there are high-stress asperities with low background stress. This procedure has a number of advantages: (1) rupture stops naturally, not at artificial barriers; (2) the amplitude of short-wavelength fluctuations of stress drop is not arbitrary: the spectrum is fixed to the long-wavelength fluctuation that determines rupture length; and (3) large stress drop can be confined to asperities occupying a small fraction of the total rupture area, producing slip distributions with enhanced peaks.