Hi Olga, I think your problem is that your frequency resolution is too poor.
You are only obtaining PSD estimates at steps of 1.5625 Hz. Look at:
This is based on your sampling frequency and window (segment) length.
Therefore the code:
VLF = [0.0033 0.04];
LF = [0.04 0.15];
HF = [0.15 0.4];
iVLF= (F>=VLF(1)) & (F<=VLF(2));
iLF = (F>=LF(1)) & (F<=LF(2));
iHF = (F>=HF(1)) & (F<=HF(2));
Is going to return a vector of zeros for iVLF, iLF, and iHF. Look at the output for
nnz(iVLF)
nnz(iLF)
nnz(iHF)
You are trying to obtain power estimates on a grid that is much finer than your frequency resolution.
Best Answer