How to use scrollable subplots in a tabbed panel? (function scrollsubplot)
이전 댓글 표시
I want to display all my calculation results in one figure window with tabbed panels.
As I would like to show multiple subplots in one tab, I started using the FileExchange function "scrollsubplot" (https://de.mathworks.com/matlabcentral/fileexchange/7730-scrollsubplot) , which seems to work fine for using subplots in an figure without tabs, but when trying to run it inside a tab panel, an error occurs.
Here is the code I use for creating simple standard subplots in a tabbed panel (which works fine, but is highly unconfortable for many subplots):
f = figure();
tab1 = uitab();
ax1 = axes('Parent', tab1);
x= linspace(-1, 1, 20);
y=x;
subplot(2,2,1);
plot(x, y);
And here ist the Code which uses the function "scrollsubplot" and displays an error:
f = figure();
tab1 = uitab();
ax1 = axes('Parent', tab1);
x= linspace(-1, 1, 20);
y=x;
scrollsubplot(2,2,1); %The only change
plot(x, y);
The Error says:
" Error using / Matrix dimensions must agree.
Error in scrollsubplot (line 247) 'sliderstep',[1/nrows 1]/(1/((nrows)/max(1,1+maxrownr(:)-minrownr(:)-nrows)))) " .
I appreciate every help and am thankful for every clue!
채택된 답변
추가 답변 (0개)
카테고리
도움말 센터 및 File Exchange에서 Axes Appearance에 대해 자세히 알아보기
제품
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!