Help with Peig function

조회 수: 5 (최근 30일)
Karin Norén-Cosgriff
Karin Norén-Cosgriff 2018년 8월 30일
댓글: Karin Norén-Cosgriff 2018년 9월 4일
Hi, I have problems understanding the meaning of nwin and nooverlaps in Peig. In the documentation it is stated that nwin is the window length and noverlap is the number of input sample points by which successive windows overlap. But the defualt values are 2xp(1) and nwin-1 respectively. Having a 18000 sample signal with one expected embedded sinusoid, I use p(1) = 2 in Peig. I would like to compare the results using a window length equal to the number of samples (and no everlaps), and dividing the signal in blocks with 6000 samples each and using 50 % overlap. How do I do this? Can someone explain and provide me with an example? Karin

답변 (1개)

Vishal Bhutani
Vishal Bhutani 2018년 9월 3일
By my understanding you want to compare results of peig function using default values of nwin and noverlap. So you can find the sample example hope it will help:
fs = 100;
t = 0:1/fs:1-1/fs;
s = 2*sin(2*pi*25*t)+sin(2*pi*35*t)+randn(1,100);
X = corrmtx(s,12,'mod');
figure(1)
peig(X,2,512,fs) % default values of nwin = p(1) = 2 and noverlap = nwin-1.
figure(2)
peig(X,2,512,fs,20,10); % specifying nwin = 20, noverlap = 10.
For your case you can specify nwin = 6000 and noverlap = 3000.
  댓글 수: 1
Karin Norén-Cosgriff
Karin Norén-Cosgriff 2018년 9월 4일
Thanks for you trying to expain this to me. However, I canot see that nwin and noverlap affects the results at all neither in your example, nor for my signal. Is it possible for you to show an example where this really has some affect for me to understand how they are working?

댓글을 달려면 로그인하십시오.

카테고리

Help CenterFile Exchange에서 Subspace Methods에 대해 자세히 알아보기

태그

제품


릴리스

R2017b

Community Treasure Hunt

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

Start Hunting!

Translated by