How can I bin the large 2D data to the same size as the smaller one and plot them by imagesc?
3 views (last 30 days)
Show older comments
Hi there,
i got two 2D data, one has larger size, the other one has smaller size, how can i bin the larger one to the size size on the y axis and plot them together by imagesc?
Thanks for your help in advance.
Regards,
PJ
0 Comments
Accepted Answer
Ameer Hamza
on 19 May 2020
Edited: Ameer Hamza
on 19 May 2020
Try imresize() to make both matrices of equal length
dataAll_noHVbg_20200517 = imresize(dataAll_noHVbg_20200517, size(dataAll_noHVbg_20200516));
figure;
ax = axes();
hold(ax);
h1 = imagesc(dataAll_noHVbg_20200516, 'AlphaData', 0.5);
h2 = imagesc(dataAll_noHVbg_20200517, 'AlphaData', 0.5);
axis tight
This plot both matrices on the same axes using transparency.
2 Comments
More Answers (0)
See Also
Categories
Find more on Graphics Performance in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!