drawLine.m 232 B

12345678
  1. function drawLine(p1, p2, varargin)
  2. %DRAWLINE Draws a line from point p1 to point p2
  3. % DRAWLINE(p1, p2) Draws a line from point p1 to point p2 and holds the
  4. % current figure
  5. plot([p1(1) p2(1)], [p1(2) p2(2)], varargin{:});
  6. end