Urgent Help!! PSD, sampling frequency, normalized frequency

Status
Not open for further replies.

gjfelix2001

Junior Member level 2
Joined
Oct 5, 2005
Messages
20
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,281
Activity points
1,359
Hi...

i'm using matlab to calculate de PSD using Welch method from a EEG record. I know that the frequencies goes from 0.5 to 15 or 30 Hz (max), as seen in the following image:



When i calculate in matlab the psd, i'm getting this:


My signal is sampled at 256 samples/second, 16 bit resolution.

What am i doing wrong?? The "shape" of the spectrum seems right but the Frequency and the power frequency doesn't..

In matlab i'm typing:

h=spectrum.welch;
Hpsd=psd(h,s,1),'NormalizedFrequency',false); % s contains the signal
plot(Hpsd) %With this i get the last plot

It is really urgent... i need to deliver this tomorrow morning....

Thanks a lot!!
 

Code:
help spectrum.welch
Might be helpful...

...or maybe just:
Code:
h=spectrum.welch; 
psd(h,s(:,1),'Fs',256);
 

Re: Urgent Help!! PSD, sampling frequency, normalized freque

Sadly, that doesn't work either... when i run

psd(h,s,1),'Fs',256);

i get this:



so,

Thanks anyway...

i don't get the utility of Fs
 

you need some way to determine the time between samples.

eg, if you had a list of number 1, 3, 2, 4, ect... there isn't anything that shows if the time between samples is 1ns, 1 day, ect...

if you sample at 256Hz, the highest frequency that you could possibly resolve* would be 128Hz. The lowest is 0Hz. Matlab doesn't know that you are only interested in the 0-30hz range.

* for your case. in general, anti-aliasing filters can be bandpass or lowpass.
 

Of course it works! If you say that your sampling frequency is 256Hz, your max frequency is 128Hz (as shown).
You only need to know what is your actual sampling rate for your captured data and substitute it in Fs...

I believe the picture you are showing is a zoomed version of the spectrum.
 

hey could you please give me the entire matlab code for eeg psd ?
 

Status
Not open for further replies.
Cookies are required to use this site. You must accept them to continue using the site. Learn more…