Closed paulroujansky closed 4 years ago
looks clean to me. Can you please update https://github.com/mne-tools/mne-features/blob/master/doc/whats_new.rst with your name and a note on the contribution?
very glad to see this package useful to some !
thx a lot @paulroujansky !
Description
In the light of the changes made in PR https://github.com/mne-tools/mne-features/pull/42 related to having more meaningful feature names when
extract_features
is called withreturn_df = True
, I extended the mechanism to every univariate functions, as most of them didn't implement aget_feature_names
method.In order to do so, I added a very basic
_compute_generic_feat_names
function that returns a list[ch0, ch1, ...]
(given input channel dim). In addition to that, I added specific feature naming functions to the following metrics:spect_edge_freq
spect_slope
wavelet_coef_energy
teager_kaiser_energy
As a consequence, the columns of the resulting dataframe are a bit more intelligible. In addition to that, I added the possibility to pass the list of channel names when calling
extract_features
in order to translate these directly in the columns.Example:
outputs
I added some tests to check these new functionnalities.