The classic answer to this problem is to multiply the signal by a "window" such as the Hamming window, so if X is your signal.
Y = X.*hamming(length(X));
You may have to transpose one of the vectors, hamming() returns a column vector.
However, the waveform you show above does not change much with tapering by a window.