How to generate a file that contains the spectrum of frequencies of a WAV/RIFF sound file?
I would like to use the Linux command line.
I know the cool SoX function to generate PNG spectrograms:
sox sound.wav -n spectrogram
But I do not need a visual representation of the spectrum of frequencies. I just want to get the spectrum of frequencies in a data file so I can work on them. I believe that there must be an option using SoX. SoX needs to generate that data before plotting it. How to get this?
Not sure, maybe the second solution is exporting the WAV file into the data file. Each sample from the data file is a measurement of the position of the membrane at a moment in time. So this is not a spectrum of frequencies.
sox sound.wav file.dat
How to convert those membrane positions into the spectrum I need?