Select and scale ground motions in ScalePy's Web Application
import scalepy
target = scalepy.targetSpectrum(0.8, 0.4, 'ZD')
keys = scalepy.recordSelection('4 9', '180 360', '0 20', 'Strike - Slip', '0 50', '0 50', '0 50', target, period=1)
scalepy.amplitudeScaling(keys, target, 1, spectral_ordinate='srss')