New function tiledlayout problems

53 visualizaciones (últimos 30 días)
Nikolaos Zafirakis
Nikolaos Zafirakis el 20 de Sept. de 2019
Respondida: Reshma Nerella el 29 de Oct. de 2020
I'm trying to use this new function tiledlayout however every time I use it, I get errors described in the code. Does anyone know a way around this? Thanks in advance!
tiledlayout(2,1); % get 100 plots
tp = theaterPlot('XLimit',[-2 2],'YLimit',[-2 2],'ZLimit',[-2 2]);
op1 = orientationPlotter(tp,'DisplayName','Rotation_Matrix1');
% if its here
% tiledlayout(2,1); % error: The layout does not have sufficient space.
for ind = 1:length(x)
% tiledlayout(2,1); % It does not make the second graph
nexttile
plot(x,y)
nexttile
% if I put these here I get 100 graphs
% tp = theaterPlot('XLimit',[-2 2],'YLimit',[-2 2],'ZLimit',[-2 2]);
% op1 = orientationPlotter(tp,'DisplayName','Rotation_Matrix1');
plotOrientation(op1,Rotation_Matrix1(:,:,ind))
drawnow
end
  1 comentario
Andrew
Andrew el 16 de Oct. de 2019
Also having the same problem. Did you figure out a solution?

Iniciar sesión para comentar.

Respuestas (2)

Bruno
Bruno el 11 de Abr. de 2020
I guess you are trying to plot 100 plots in a grid of 2x1, which only could contain 2 plots. I guess you want to make tiledlayout(50,2)

Reshma Nerella
Reshma Nerella el 29 de Oct. de 2020
Hi,
tiledlayout(m,n) % Gives you m*n plots
tiledlayout(2,1) % Gives you only 2 plots
Since you want 100 plots, you should give m,n values such that m*n = 100
For more information and examples on tiledlayout, refer to the documentation page: tiledlayout

Categorías

Más información sobre 2-D and 3-D Plots en Help Center y File Exchange.

Community Treasure Hunt

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

Start Hunting!

Translated by