Matlab R2016a MLX generated figure no response
1 次查看(过去 30 天)
显示 更早的评论
Hi, I am using Matlab R2016a live script to generate and save some figures. The figures were generated and shown in the live script. They were also saved as .fig file. But when i double clicked them, nothing happens. I wonder if there is something wrong with my installation.
Best, Ming
0 个评论
采纳的回答
Matt Cohen
2016-5-9
Hi Ming,
This issue is likely related to a default setting made by the Live Editor when working with figures. The figure is probably not being displayed here because it is loaded invisible. When you use live scripts, the 'Visible' property of the figure is set to off because the preview that you see on the right is just a screenshot rather that a docked figure.
To make the figure visible, you would have to set the figure's 'Visible' property to on. You can do this using one of the following two code snippets:
% Assuming variable 'filename' contains the figure's name
f = openfig(filename)
f.Visible = 'on'
or
openfig(filename,'visible')
I hope this helps.
Matt
更多回答(1 个)
Nikhil Vyas
2016-4-25
It might be possible that the *.fig extension files are not associated with MATLAB. You can change file association in Windows by the following procedure:
Right click the file > Properties > General > Opens With > Change > Select MATLAB.
Additionally, you can try opening the .fig file inside MATLAB using the following command:
openfig('filename.fig');
In case your file is not in your workspace path, you can copy it there. Or you can use an absolute filename like:
openfig('D:\some_folder\some_other_folder\filename.fig');
0 个评论
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Printing and Saving 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!