comparison scripts/plot/draw/private/__quiver__.m @ 32038:29671873411a

__quiver__.m: Honor scaling factor input for single quiver arrow (bug #39552) * scripts/plot/draw/private/__quiver__.m: Change scaling factor check to include cases where there is only one quiver arrow. * etc/NEWS.9.md: Note quiver change under General Improvements.
author Nicholas R. Jankowski <jankowski.nicholas@gmail.com>
date Wed, 19 Apr 2023 10:36:29 -0400
parents 597f3ee61a48
children ada96a467a28
comparison
equal deleted inserted replaced
32037:619e2314ebba 32038:29671873411a
147 ww = w; 147 ww = w;
148 len = max (sqrt (u(:).^2 + v(:).^2 + w(:).^2)); 148 len = max (sqrt (u(:).^2 + v(:).^2 + w(:).^2));
149 else 149 else
150 len = max (sqrt (u(:).^2 + v(:).^2)); 150 len = max (sqrt (u(:).^2 + v(:).^2));
151 endif 151 endif
152 if (len > 0 && autoscale && numel (u) > 1) 152 if (len > 0 && autoscale && numel (u) >= 1)
153 if (isvector (x)) 153 if (isvector (x))
154 nx = ny = sqrt (length (x)); 154 nx = ny = sqrt (length (x));
155 else 155 else
156 [ny, nx] = size (x); # assume meshgrid fmt, x in columns, y in rows 156 [ny, nx] = size (x); # assume meshgrid fmt, x in columns, y in rows
157 endif 157 endif