我已经阅读、测试了这个文档和这个例子,并自己尝试过,但还没有找到所描述问题的解决方案。
根据文档,图像文件与使用的 MATLAB 脚本位于同一路径上,在这种情况下,可以按照描述轻松添加它
% <<Filename.png>>
或者需要添加完整路径:
% <<C:\\Fullpath\Filename.png>>
否则会得到一个空文档(至少在publish
创建 .html 文件时)。
由于应共享记录的代码,我需要一个相对路径以避免以后出现问题。
MATLAB 中是否有任何解决方案或变通方法?
我以前的一些尝试:
% <<.\Filename.png>> # with and without "" or ''
% <<..\Filename.png>> # with and without "" or ''
% <<..\..\Filename.png>> # with and without "" or ''
图像不出现。
本文收集自互联网,转载请注明来源。
如有侵权,请联系 [email protected] 删除。
我来说两句