MATLAB: How to normalize well data between [-1,1]

digital signal processingMATLABnormalizationscaling

Proposal which gives a results which looks correct; Can you return the original vector from the normalised result?
% https://se.mathworks.com/matlabcentral/answers/154075-how-to-scale-normalize-values-in-a-matrix-to-be-between-1-and-1
a = -1 + 2.*(a - min(a))./(max(a) - min(a));
Other proposed normalizations but they do not work, giving wrong range
a = normalize(a);
a = a/norm(a);
I am processing MIT-BIH arrythmia database signals.
MATLAB: 2016b OS: Debian 8.5

Best Answer

Well, think about it! Without knowledge of the scaling and translation done, how could you possibly regenerate the original data? If you discard information content, that information is lost.
Were you to save that information, (i.e., the min and max of your data) then it is trivial to reverse the normalization.
And of course the two alternatives you list don't work, since both a translation and scaling are needed to achieve the final range you desire.