FUNCTION REFERENCE

periodogram

Windowed single-segment power spectrum or density.

Windowed single-segment power spectrum or density.

Syntax

[pxx,w] = periodogram(x,window,nfft)

Syntax

[pxx,f] = periodogram(x,window,nfft,fs,'onesided','psd')

Optional arguments may be omitted or replaced by []. Defaults: rectangular window covering x, nfft=max(256,next power of two of length(x)), no detrending, one-sided for real input and two-sided for complex input. Without fs, frequency is radians/sample and density is power per radian/sample; with fs it is Hz and power/Hz. Trailing 'onesided', 'twosided', or 'centered' selects the range; 'power' divides by squared window sum instead of fs times window energy. Interior one-sided powers double, excluding DC and an even-length Nyquist bin. Matrix columns are independent channels. With no outputs, plots dB versus frequency.

Example

[p,w] = periodogram([1 0 -1 0],[],16);

Example

[p,f] = periodogram(1:16,[],32,100,'centered','power');

Differences from MATLAB: only finite 2-D arrays; window must cover the entire signal, FFT length must be at least window length, and frequency vectors as FFT specifications are unsupported. FFT length is limited to 1048576, with additional work and memory limits.

These are the engine’s help pages. Each page keeps its compatibility notes. File operations are unavailable in the browser.