Scrollsubplot

버전 1.2.0.0 (32.5 KB) 작성자: Bjorn Gustavsson
scrollsubplot(n,m,p) p<0 and p>nm, Extends subplot to infinite canvas ...
다운로드 수: 4.8K
업데이트 날짜: 2014/2/3

라이선스 보기

편집자 메모: This file was selected as MATLAB Central Pick of the Week

SCROLLSUBPLOT Create axes in tiled positions.

SCOLLSUBPLOT(m,n,p), breaks the Figure window into
an m-by-n matrix of small axes, selects the p-th axes for the current plot, and returns the axis handle. The axes are counted along the top row of the Figure window, then the second row, etc. For example,

SCROLLSUBPLOT(3,1,-1), PLOT(income)
SCROLLSUBPLOT(3,1,1), PLOT(declared_income)
SCROLLSUBPLOT(3,1,2), PLOT(tax)
SCROLLSUBPLOT(3,1,3), PLOT(net_income)
SCROLLSUBPLOT(3,1,4), PLOT(the_little_extra)

plots declared_income on the top third of the window, tax in the middle, and the net_income in the bottom third. Above the top of the figure income is ploted and below the lower edge
the_little_extra is to be found. To navigate there is a slider along the right figure edge.

SCROLLSUBPLOT now also work with less regular subplot-layouts:

axs3(1) = scrollsubplot(3,3,1);
axs3(2) = scrollsubplot(3,3,3);
axs3(3) = scrollsubplot(3,3,[4,7]);
axs3(4) = scrollsubplot(3,3,5);
axs3(5) = scrollsubplot(3,3,[3,6]);
axs3(6) = scrollsubplot(3,3,10);
axs3(7) = scrollsubplot(3,3,[8,9,11,12]);
axs3(8) = scrollsubplot(3,3,[13,14,15);
for i1 = 1:8,
if ishandle(axs3(i1))
axes(axs3(i1))
imagesc(randn(2+3*i1))
end
end

The function works well for regular grids where m,n is constant for all p. When m,n varies there is no guaranti that the steps of the slider is nicely adjusted to the sizes of the subplots.

SCROLLSUBPLOT now also works with mouse-wheel scroll.

Differences with SUBPLOT: SCROLLSUBPLOT requires 3 input arguments, no compatibility with subplot(323), no handle as input. Further PERC_OFFSET_L is decreased from 2*0.09 to 0.07
and PERC_OFFSET_R is decreased from 2*0.045 to 0.085. This leaves less space for titles and labels, but give a plaid grid of subplots even outside the visible figure area.

Bug/feature when the slider is shifted from its initial position and then extra subplots is added, they get mis-positioned.

See also SCROLL, SUBPLOT,

인용 양식

Bjorn Gustavsson (2025). Scrollsubplot (https://kr.mathworks.com/matlabcentral/fileexchange/7730-scrollsubplot), MATLAB Central File Exchange. 검색 날짜: .

MATLAB 릴리스 호환 정보
개발 환경: R13SP1
모든 릴리스와 호환
플랫폼 호환성
Windows macOS Linux
카테고리
Help CenterMATLAB Answers에서 Axes Appearance에 대해 자세히 알아보기
도움

도움 받은 파일: Scrolling Plot Demo, Scrolling Figure Demo

Community Treasure Hunt

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

Start Hunting!
버전 게시됨 릴리스 정보
1.2.0.0

Now handles irregular tiling of subplots, and responds to mouse-wheel scrolling.

1.0.0.0