フィルターのクリア

Error with figure color function

1 回表示 (過去 30 日間)
Muaaman
Muaaman 2014 年 12 月 14 日
コメント済み: Muaaman 2014 年 12 月 14 日
I am trying to display a figure with color so I am entering:
function class1()
figure('name', 'Example',...
'numbertitle', 'off',...
'menubar', 'none'...
'color',[1 1 1])
end
But I get an error:
Error: File: class1.m Line: 6 Column: 5
Unexpected MATLAB expression.
How do I fix it so I can set colour to the figure? Assistance would be greatly appreciated. MATLAB version: R2012a

採用された回答

Image Analyst
Image Analyst 2014 年 12 月 14 日
You forgot a command after 'none'. Try this:
hFigure = figure('name', 'Example',...
'numbertitle', 'off',...
'menubar', 'none',... % Here's where you were missing the comma
'color', [.1 .8 .5])
  1 件のコメント
Muaaman
Muaaman 2014 年 12 月 14 日
Thank you very much Image Analyst. The error is now corrected.

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

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeInteractive Control and Callbacks についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by