[英]Insert 2 image on the figure when I have corresponding x and y coordinates
我需要關於如何通過每個 png 的 x 和 y 坐標在當前圖形(即國家的 map)上插入 two.png 圖像的任何指導。 我在 PowerPoint 中完成了此操作(見下圖),但由於我有超過 2000 分,如果可以在 Matlab 之前完成,那就太棒了。
當前數字是國家 map,我的兩個 png 是這兩個彩色圓圈。
謝謝你們
這是一個簡單的方法:假設im1
是您的圈子 map, im2
是伊朗的 map。
im1 = ones(64);
im1(20:40,20:40) = 0.5;
im2 = rand(64);
figure
imshow(im1,[]);
hold on
h = imshow(im2,[]);
h.AlphaData = 0.3; % or whatever Transparency makes you happy
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.