フィルターのクリア

resize of axes

1 回表示 (過去 30 日間)
Pan
Pan 2012 年 3 月 11 日
I want to ask that axes can resize?

回答 (2 件)

Image Analyst
Image Analyst 2012 年 3 月 11 日
Or, if you meant the actual size of the axes, instead of the range of the axes, then you can use set() to set the position (which is both the position and the size):
set(handleToYourAxes, 'Position', [.1 .2 .8 .8]); % Or whatever size you want.
  2 件のコメント
Pan
Pan 2012 年 3 月 11 日
I want to the picture that resize when figure resize.
this is code
h1 = figure('Name','Video ', 'NumberTitle','off','Color',[1,1,1],'Toolbar','none','Visible','on', 'Position',[30 40 970 700],...
'Resize','on','menu','none');
pic = imread('search.bmp');
ax1 = axes('parent',h1,'unit','pixel','position',[300 100 500 500]);
imagesc(pic,'parent',ax1); colormap(gray); axis(ax1,'off');
Image Analyst
Image Analyst 2012 年 3 月 11 日
Then set the 'Units' property of your axes to 'Normalized' - not 'pixel'. If you do that then when you resize your window (main figure), the axes on it will scale proportionally.

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


Honglei Chen
Honglei Chen 2012 年 3 月 11 日
There are many functions
doc xlim
doc ylim
doc axis
  2 件のコメント
Pan
Pan 2012 年 3 月 11 日
How to use it?? I have no idea.
Daniel Shub
Daniel Shub 2012 年 3 月 11 日
If you type doc xlim at the command line, you will get all the help you need to use xlim.

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

カテゴリ

Help Center および File ExchangeVisual Exploration についてさらに検索

タグ

Community Treasure Hunt

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

Start Hunting!

Translated by