簡體   English   中英

當我有相應的 x 和 y 坐標時,在圖形上插入 2 個圖像

[英]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.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM