I have an FFT to plot. The FFT data is stored in a QwtSeriesData object (this is Qwt6 and Qt4.6.2 BTW) so it is stored as a magnitude only, with the sample position (index) being the x-axis value.

When plotted in this form I have a graph which shows the FFT as magnitude (dBFS) on the y-axis against FFT sample bin on the x-axis (the sample bin is effectively the FFT point size).

This is OK for some applications as knowing the frequency bin in useful, however it is more normal to plot the FFT as magnitude against frequency. The conversion from FFT bin to frequency is a simple scale factor. Is it possible to do this by simply modifying the way the x-axis is scaled?

I am sure this is possible, but maybe the search criteria I have tried do match anything posted on the forum, so possible apologies in advance if this is an obvious answer. Or if its in the Qwt docs maybe again I am looking at the wrong thing. I thought it was something to do with the scale engines but am not so sure now.

Cheers

Oh forgot to say, I am plotting multiple curves on a single plot and was using the auto scale to set the appropriate scale for all plots. Not sure if this changes how this is done.

## Bookmarks