# [Eeglablist] reg individual frequencies plotting

Makoto Miyakoshi mmiyakoshi at ucsd.edu
Tue Oct 7 13:00:58 PDT 2014

```Dear Nishanth,

This is the basic idea.

%%%%%%%%%%%%%%%%%%%
% for your epoched data, channel 2
[spectra,freqs] = spectopo(EEG.data(2,:,:), 0, EEG.srate);

% delta=1-4, theta=4-8, alpha=8-13, beta=13-30, gamma=30-80
deltaIdx = find(freqs>1 & freqs<4);
thetaIdx = find(freqs>4 & freqs<8);
alphaIdx = find(freqs>8 & freqs<13);
betaIdx  = find(freqs>13 & freqs<30);
gammaIdx = find(freqs>30 & freqs<80);

% compute absolute power
deltaPower = 10^(mean(spectra(deltaIdx))/10);
thetaPower = 10^(mean(spectra(thetaIdx))/10);
alphaPower = 10^(mean(spectra(alphaIdx))/10);
betaPower  = 10^(mean(spectra(betaIdx))/10);
gammaPower = 10^(mean(spectra(gammaIdx))/10);
%%%%%%%%%%%%%%%%%

If you don't want to code, maybe you want to try the following toolbox.
http://www.poil.dk/s/#.VDRGNZTWXNU

Makoto

On Wed, Oct 1, 2014 at 10:47 AM, nishanth reddy <nishanth.reddy56 at gmail.com>
wrote:

> how can i get the average eeg power densities in the delta,theta,alpha and
> beta wave bands in the light period?
>
> --
> Thanks&Regards
>
> Nishanth
>
> _______________________________________________
> Eeglablist page: http://sccn.ucsd.edu/eeglab/eeglabmail.html
> To unsubscribe, send an empty email to
> eeglablist-unsubscribe at sccn.ucsd.edu
> For digest mode, send an email with the subject "set digest mime" to
> eeglablist-request at sccn.ucsd.edu
>

--
Makoto Miyakoshi
Swartz Center for Computational Neuroscience
Institute for Neural Computation, University of California San Diego
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://sccn.ucsd.edu/pipermail/eeglablist/attachments/20141007/e00e5bdb/attachment.html>
```