Hi Corrado, I'm sure that worked because the baseline drift is DC and you applied a high pass filter. You can also try to use detrend() and see if that does as well as your highpass filter.
y = detrend(x); % removes the best linear fit
y = detrend(x,'constant'); % makes the data zero mean
Wayne