# mne\_feature problem with compute\_pow\_freq\_bands function

**URL:** <https://mne.discourse.group/t/mne-feature-problem-with-compute-pow-freq-bands-function/7262>\
**Category:** Support & Discussions\
**Tags:** preprocessing, eeg\
**Created:** [July 19, 2023, 1:30pm UTC](https://mne.discourse.group/t/mne-feature-problem-with-compute-pow-freq-bands-function/7262 "2023-07-19T13:30:10Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![jack\_hu](https://avatars.discourse-cdn.com/v4/letter/j/e274bd/32.png) [@jack\_hu](https://mne.discourse.group/u/jack_hu)\
**Post date:** [July 19, 2023, 1:30pm UTC](https://mne.discourse.group/t/mne-feature-problem-with-compute-pow-freq-bands-function/7262/1 "2023-07-19T13:30:10Z")

</div>

I am using the mne\_feature for feature extraction:` mne_features.univariate.compute_pow_freq_bands`

`X.shape` : (23528, 18, 30000)

```python
import mne_features
mne_features.univariate.compute_pow_freq_bands(100,X[0])

```

this is for the first epoch X[0] , it will work.

However, if i ran the following:

`mne_features.univariate.compute_pow_freq_bands(100,X)`

it will not work.dimention not match in the error  
my question is, is there a function to extraction the power\_freq\_bands for all epochs in one time?

---

<div class="post-metadata">

**Author:** ![agramfort](https://avatars.discourse-cdn.com/v4/letter/a/7c8e57/32.png) [@agramfort](https://mne.discourse.group/u/agramfort)\
**Post date:** [July 19, 2023, 3:44pm UTC](https://mne.discourse.group/t/mne-feature-problem-with-compute-pow-freq-bands-function/7262/2 "2023-07-19T15:44:02Z")

</div>

use [https://mne.tools/mne-features/generated/mne\_features.feature\_extraction.extract\_features.html#mne\_features.feature\_extraction.extract\_features](https://mne.tools/mne-features/generated/mne_features.feature_extraction.extract_features.html#mne_features.feature_extraction.extract_features)  
passing good function to selected\_funcs

see example [https://mne.tools/mne-features/auto\_examples/plot\_mne\_sample\_features.html#sphx-glr-auto-examples-plot-mne-sample-features-py](https://mne.tools/mne-features/auto_examples/plot_mne_sample_features.html#sphx-glr-auto-examples-plot-mne-sample-features-py)

Alex

---

<div class="post-metadata">

**Author:** ![jack\_hu](https://avatars.discourse-cdn.com/v4/letter/j/e274bd/32.png) [@jack\_hu](https://mne.discourse.group/u/jack_hu)\
**Post date:** [July 19, 2023, 4:05pm UTC](https://mne.discourse.group/t/mne-feature-problem-with-compute-pow-freq-bands-function/7262/3 "2023-07-19T16:05:13Z")

</div>

Thank you so much！
