Figure without border?
103 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
Marina
am 10 Jul. 2019
Kommentiert: Marina
am 10 Jul. 2019
hello,
Can you make a figure without a border? I need the data to ocupy the entire figure window. Is this possible?
thanks,
marina
0 Kommentare
Akzeptierte Antwort
Adam Danz
am 10 Jul. 2019
Bearbeitet: Adam Danz
am 10 Jul. 2019
fh = figure('Menu','none','ToolBar','none');
ah = axes('Units','Normalize','Position',[0 0 1 1])
ADDENDUM
If you're using axis square you'll need to make sure the figure position is also square. Here's a demo following the block above:
plot(rand(1000,1),rand(1000,1),'ko')
axis(ah, 'square')
fh.Position(3) = fh.Position(4); %set width equal to height
2 Kommentare
Weitere Antworten (1)
Steven Lord
am 10 Jul. 2019
When you say "figure" do you mean the figure object (the window on the screen) or the axes contained in the figure? I've seen people use that word in both meanings.
If you want to maximize the figure object (the window on the screen) and you're using release R2018a or later, use the WindowState property of the figure object.
If you want to make the axes span the entirety of the figure window, do as Adam Danz suggested.
If you want the axes to span the entirety of a maximized figure object, combine Adam's suggestion and mine. Maximize the figure then make the axes with 'Units', 'normalized' and 'Position', [0 0 1 1].
Siehe auch
Kategorien
Mehr zu Graphics Object Programming finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!