Skip to content

Commit db8b1b1

Browse files
author
Ross Hatton
committed
fixed mfield draw structure and >2 warning
1 parent 99aed50 commit db8b1b1

File tree

1 file changed

+12
-4
lines changed

1 file changed

+12
-4
lines changed

ProgramFiles/sys_draw_fcns/mfield_draw.m

Lines changed: 12 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,11 @@
1111
% Get the number of dimensions
1212
n_dim = numel(s.grid.eval);
1313

14+
%Ensure that there are figure axes to plot into, and create new windows
15+
%for those axes if necessary
16+
plot_info = ensure_figure_axes(plot_info);
17+
18+
1419
if n_dim==2
1520

1621
%Vector field list
@@ -19,9 +24,6 @@
1924
% Get the number of dimensions
2025
% n_dim = numel(s.grid.eval);
2126

22-
%Ensure that there are figure axes to plot into, and create new windows
23-
%for those axes if necessary
24-
plot_info = ensure_figure_axes(plot_info);
2527

2628
%%%%%%%
2729
% Get the vector field and interpolate into the specified grid
@@ -226,7 +228,13 @@
226228

227229
end
228230
else
229-
text(0.1,0.5,'Illustration of metric field not implemented for >2 shape variables')
231+
for i = 1:length(plot_info.axes)
232+
233+
%call up the relevant axis
234+
ax = plot_info.axes(i);
235+
text(0.1,0.5,'Illustration of metric field not implemented for >2 shape variables','Parent',ax)
236+
237+
end
230238
end
231239

232240
end

0 commit comments

Comments
 (0)