log scale y-axis for periodogram

9 ビュー (過去 30 日間)
Philippe
Philippe 2014 年 2 月 11 日
編集済み: Mischa Kim 2014 年 2 月 11 日
The periodograms from an electronic signal I am analyzing have such high power periodicity in the low frequency bandwidths that, without zooming in on the data, these are almost impossible to read. (see the example below) Is it possible, when using the [(pxx,f) = periodogram(x,window,nfft)], to adjust the y-axis to a log-scale to improve the graph's readibility? The y-axis in the example represents the magnitude of the periodogram (i.e. abs(pxx)).

回答 (1 件)

Mischa Kim
Mischa Kim 2014 年 2 月 11 日
編集済み: Mischa Kim 2014 年 2 月 11 日
Philippe, it is. Use
pxx = periodogram(x,window,nfft)
plot(10*log10(pxx))
to plot the periodogram.
  2 件のコメント
Philippe
Philippe 2014 年 2 月 11 日
Dear Mischa,
Thanks for your answer. However, in the presented periodogram I've plotted the frequency vector f (output from [(pxx,f) = periodogram(x,window,nfft)]) against the magnitude of pxx (through calculating abs(pxx)). This wasn't clearly put in the original question, I've now adjusted it.
As you said, plot(10*log10(pxx)) gives a log-scale y-axis, but - and I'm probably overlooking something - until now I've not succeeded in converting my magnitude axis to a log-scale..
Mischa Kim
Mischa Kim 2014 年 2 月 11 日
I am not quite sure I understand. For plotting frequency vs. pxx you would use
plot(f,10*log(pxx))
instead, correct. Is that what you are referring to? Or are you still not able to get the log-scale on the y-axis?

サインインしてコメントする。

カテゴリ

Help Center および File ExchangeSpectral Estimation についてさらに検索

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by