Why is colormap only applied to the last subplot?
6 ビュー (過去 30 日間)
古いコメントを表示
Hello. I made a custom (circular) colormap for phase angles. However, in the loop, only the last subplot takes the change. What is the issue in this code? Thanks!
figure
for i = 1:5
subplot(2, 5, i);
topoplot(double(squeeze(pophmat(timeidx, i, :, 1))), EEG.chanlocs, ...
'style', 'map', 'electrodes', 'off');
title(['Pwr: ' num2str(frequencies(i)) 'Hz, 180ms']);
subplot(2, 5, i+5);
topoplot(double(squeeze(pophmat(timeidx, i, :, 2))), EEG.chanlocs, ...
'style', 'map', 'electrodes', 'off');
title(['Phs: ' num2str(frequencies(i)) 'Hz, 180ms']);
colormap(gca, circular_jet); % Applying the custom colormap to the current subplot
end
2 件のコメント
採用された回答
その他の回答 (0 件)
参考
カテゴリ
Help Center および File Exchange で Subplots についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!