I have been reading about the Wavelet transform recently and its relationship to the Fourier transform. From what I understand the wavelet transform represents signal data with many short-lived functions (wavelets). The major difference between the 2 is that the Fourier does not sample in time, but only in frequency. I have couple questions about the wavelet method:
1) Why is it required that wavelet functions integrate to 0?
From my understanding, wavelets are shifted along the time domain and compressed or stretched to match the frequency of the signal at that point in time. So wavelets are able to capture frequency at different places in time.
2) How does the wavelet capture peaks that are higher or lower in the original domain? For example see the image below that I have simulated in R. The dashed line represents the wavelet transformed approximation. How is this dashed line able to capture peaks that are higher or lower if it is only shifted and compressed or stretched in the x direction?