rearranging waveform figures