Drexel dragonThe Math ForumDonate to the Math Forum



Search All of the Math Forum:

Views expressed in these public forums are not endorsed by Drexel University or The Math Forum.


Math Forum » Discussions » Software » comp.soft-sys.matlab

Topic: axis size changes when removing tick labels
Replies: 6   Last Post: Jan 22, 2013 4:23 PM

Advanced Search

Back to Topic List Back to Topic List Jump to Tree View Jump to Tree View   Messages: [ Previous | Next ]
rachael

Posts: 16
Registered: 2/10/09
axis size changes when removing tick labels
Posted: Jan 9, 2013 2:27 PM
  Click to see the message monospaced in plain text Plain Text   Click to reply to this topic Reply

Is there a simple way to fix the axis size so that it stays the same size w/ or w/o tick labels?

Currently, when I set my 'yticklabel' to [], my axes2 become larger. I would like it to stay the same size w/ or w/o labels.

I'm running matlab R2012b (8.0.0.783) on OSX Mountain Lion.

Code is below

fig = figure;
set(fig, 'color','w');
hndl = axes('Position',[0 0 1 1], 'Visible','off','color','w');

axes1 = axes(...
'OuterPosition', [0.1 0.1 0.3 0.7], ...
'Parent', fig, ...
'fontsize', 12);

axes2 = axes(...
'OuterPosition', [0.5, 0.1 0.3 0.7],...
'Parent', fig, ...
'fontsize', 12, ...
'yticklabel', []);

hold(axes1,'all');
hold(axes2,'all');

% plot bathymetry
pcolor(axes1, xl, yl, h_l);
pcolor(axes2, xw,yw,h_w);
shading(axes1, 'flat');
shading(axes2, 'flat');



Point your RSS reader here for a feed of the latest messages in this topic.

[Privacy Policy] [Terms of Use]

© Drexel University 1994-2014. All Rights Reserved.
The Math Forum is a research and educational enterprise of the Drexel University School of Education.