Error when saving figure with linux command line

9 ビュー (過去 30 日間)
Spencer DeLange
Spencer DeLange 2022 年 4 月 26 日
コメント済み: Ruben Krueger 2023 年 12 月 21 日
Receiving an error when I try and save a figure as a png. See traceback below. Calling matlab from a python script with -batch flag.
Error using validate (line 166)
Printing of uicontrols is not supported on this platform.
Error in print (line 67)
pj = validate( pj );
Error in saveas (line 181)
print( h, name, ['-d' dev{i}] )
Error in NavErrPlotsLN25X (line 238)
saveas(figH,fullfile(uutData.ftp(1).folder,figFileName),'png');
Error in NavErrPlotsProgramSwitch (line 42)
statusLog = NavErrPlotsLN25X(uutData,config,statusLog);
Error in FTPReviewWeb (line 51)
log = NavErrPlotsProgramSwitch(uutData,config,log);

回答 (1 件)

Jan
Jan 2022 年 4 月 26 日
編集済み: Jan 2022 年 4 月 26 日
In batch mode, Matlab does not support interactive GUI elements.
print('-noui', ...)
  1 件のコメント
Ruben Krueger
Ruben Krueger 2023 年 12 月 21 日
In my use case, I need the buttons because their labels have critical information, but I don't need their functionality, of course. I am having the same issue as above when trying to save a figure in a Matlab executable. How can print with the UI?

サインインしてコメントする。

カテゴリ

Help Center および File ExchangeCall Python from MATLAB についてさらに検索

タグ

製品


リリース

R2021a

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by