Finding period of EEG (peak2peak)
5 visualizaciones (últimos 30 días)
Mostrar comentarios más antiguos
The dataset im working on is EEG signals. I have a variable tsout which is a timeseries object containing 1x600 timeseries.
The data is arranged so that the each column contains a 1s segment of the total timeseries of length 600s. For instance, col 1 represents 0-1s , col2 represent 1-2s and etc. I would like to find the local maximum in these data.
I used this code:
[pks,locs]=findpeaks(tsout)
and obtained this errors
Error using findpeaks
Expected Y to be one of these types:
double, single
Instead its type was timeseries.
Error in findpeaks>parse_inputs (line 199)
validateattributes(Yin,{'double','single'},{'nonempty','real','vector'},...
Error in findpeaks (line 136)
= parse_inputs(isInMATLAB,Yin,varargin{:});
I would like to successive periods based on the peak2peak time values, for every 1 s of the data adn categorize these T calculated according to their time interval(seconds). For instance Period_1 contains all the successive T from 0-1s and so forth.
I am not sure how to implement this and join it w the code for finding peaks. But was thinking of sth like this.
T{i}=locs(2:end) - locs(1:end-1)
Thank you in advance!
0 comentarios
Respuestas (1)
Ver también
Categorías
Más información sobre EEG/MEG/ECoG en Help Center y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!