i need to know if its possible to plot a certain number of datas and then plot the next in another plot and so on
3 ビュー (過去 30 日間)
古いコメントを表示
i have an EEG dataset in a file with an odd extension 'eea'
i managed to be able to read it in matlab and plot it, but each 7680 numbers represent one channel, and the whole data of the patient is 122880, i want to know if there is a way to code a script so that it automatically grabs the firs 7680 datas and then the next and so on and plots them separately, also if its possible to plot it and make it look like one of those EEG data plots graphs and with a name on each one
my code:
clc; clear; close all;
data = load('S196W1.eea');
plot(data);
xlim([-2000 125000])
ylim([-2550 2550])
grid
% Avoid exponential notation and have the Y axis locked during a zoom
Ax = gca;
Ax.XAxis.Exponent = 0;
Ax.YAxis.TickLabelFormat='%d';
Ax.YAxis.Exponent =0;
set(zoom(gcf),'Motion','horizontal','Enable','on');
>>from looking like this
>>to something that is similar to this
0 件のコメント
採用された回答
Voss
2024 年 6 月 4 日
編集済み: Voss
2024 年 6 月 4 日
% data = load('S196W1.eea');
data = 500*randn(122880,1); % random data the same size as yours
n_channels = 16;
data_plot = reshape(data,[],n_channels)./max(abs(data),[],'all')+(1:n_channels);
plot(data_plot)
yticks(1:n_channels)
yticklabels(compose("Ch-%02d",1:n_channels))
その他の回答 (0 件)
参考
カテゴリ
Help Center および File Exchange で EEG/MEG/ECoG についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!