Skip to content

Commit

Permalink
check that 2D points are passed, just to be clear.
Browse files Browse the repository at this point in the history
  • Loading branch information
petercorke committed Jul 8, 2018
1 parent 60418f9 commit 88d8dd0
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion plot_point.m
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@
% - Points can be drawn in 3D axes but will always lie in the
% xy-plane.
%
% See also PLOT, TEXT.
% See also PLOT_SPHERE, PLOT, TEXT.


% Copyright (C) 1993-2017, by Peter I. Corke
Expand Down Expand Up @@ -89,8 +89,13 @@
p = [[p.u_]; [p.v_]];
end

if numrows(p) == 3
error('p must have 2 rows, only supports 2D plotting')
end
holdon = ishold();
hold on
h = zeros(1,numcols(p));

for i=1:numcols(p)
if opt.solid
arglist = [ 'MarkerFaceColor', ls{1}(1), arglist];
Expand Down

0 comments on commit 88d8dd0

Please sign in to comment.