当前位置:网站首页>matlab讀取多張fig圖然後合並為一張圖(子圖的形式)
matlab讀取多張fig圖然後合並為一張圖(子圖的形式)
2022-04-23 03:54:00 【subtitle_】
引言
多次做實驗得到了一些實驗的圖像,matlab導出保存為了fig格式,想讀取多張fig圖然後合成為一張大圖(子圖的形式),查了一些資料,記錄一些自己的思考和體會。
1.代碼
for i=1:10
%打開的fig文件酌情修改路徑
hf(i)=open(['.\fig\sin-x1-test_',num2str(i),'.fig']);%打開fig
fig(i)=get(hf(i), 'CurrentAxes');%獲取繪制的圖像
end
%新建一個圖窗
figure
for i=1:10
%看要繪制多少行多少列酌情改變
subplot(2,5,i);%第i個子圖
axChildren = get(fig(i),'Children');%獲取繪制的圖像
copyobj(axChildren, gca);%複制到當前圖窗裏
close(hf(i));%關掉已經複制的圖像
%下面是對圖片進行設置,請酌情修改
title(['S曲線第',num2str(i),'次測試']);%繪制子圖標題
xlabel('Angle(\circ)');%繪制子圖x標簽
ylabel('Center WaveLength Change(nm)');%繪制子圖y標簽
yaxis([-0.05,0.2])%繪制子圖y的範圍
xticks([0 20 40 60 80 100]);%繪制子圖刻度
end
2.最終效果如圖
版权声明
本文为[subtitle_]所创,转载请带上原文链接,感谢
https://yzsam.com/2022/04/202204230353257558.html
边栏推荐
- 变量、常量、运算符
- Opencv4 QR code recognition test
- 知乎有问题,谁来解答?
- What if win10 doesn't have a local group policy?
- MySQL is completely uninstalled and MySQL service is cleaned up
- Machine translation baseline
- Xiaomi, which has set the highest sales record of domestic mobile phones in overseas markets, paid renewed attention to the domestic market
- [AI vision · quick review of robot papers today, issue 30] Thu, 14 APR 2022
- Openvino only supports Intel CPUs of generation 6 and above
- Abstract classes, interfaces and common keywords
猜你喜欢
Writing latex with vscode - the latest tutorial 2022 / 4 / 17
AI CC 2019 installation tutorial under win10 (super detailed - small white version)
深度學習筆記(二)——激活函數原理與實現
[AI vision · quick review of robot papers today, issue 29] Mon, 14 Feb 2022
使用大华设备开发行AI人流量统计出现时间不正确的原因分析
QT program integration easyplayer RTSP streaming media player screen flicker what is the reason?
Identificateur, mot - clé, type de données
Add the compiled and installed Mysql to the path environment variable
Hard core chip removal
Identifier, keyword, data type
随机推荐
Network principle | connection management mechanism in TCP / IP important protocol and core mechanism
Use of rotary selector wheelpicker
What is software acceptance testing? What are the benefits of acceptance testing conducted by third-party software testing institutions?
【李宏毅2022 机器学习春】hw6_GAN(不懂..)
Design and implementation of redis (2): how to handle expired keys
Second kill all interval related problems
伦敦银最新价格走势图与买卖点
Retrieval question answering system baseline
Xiaomi, qui a établi le plus grand volume de ventes de téléphones portables domestiques sur le marché d'outre - mer, se concentre de nouveau sur le marché intérieur
Raspberry pie 3B logs into the wired end of Ruijie campus network through mentohust, creates WiFi (open hotspot) for other devices, and realizes self startup at the same time
Design and implementation of redis (4): what is the event driver of redis
Common auxiliary classes
Shopping mall for transportation tools based on PHP
【NeurIPS 2019】Self-Supervised Deep Learning on Point Clouds by Reconstructing Space
[latex] formula group
Operating skills of spot gold_ Wave estimation curve
【测绘程序设计】坐标反算神器V1.0(附C/C#/VB源程序)
Nel ASA: her ø Ya facility in Norway officially opened
Design and implementation of redis (1): understand data structures and objects
[string] ranking of country names ----- problem solving notes