I just wanted to express the Normalized part of the magnitude axis label using the Normalized
function. True,Normalized
will just find a factor that is applied to all numbers, and one just has to pick the right norm. Here is an example of how to scale a list of non-negative random numbers such that the maximum is 1 after normalization:
In[1]:= mag = RandomReal[{0, 100}, {10}];
In[2]:= Max[mag]
Out[2]= 99.6271
In[3]:= magNormalized = Normalize[mag, Norm[#, \[Infinity]] &];
In[4]:= Max[magNormalized]
Out[4]= 1.
The reason for using Normalized
is to make the intention clear, but there are also situations where it is convenient to use Normalized
since the data (in this case mag
) does not have to be repeated. In the end, the result is the same as:
magNormalized = (1 / Norm[mag, \[Infinity]]) mag;