Rearrange X and Y coordinates before calling "lines()" function.

orderedLines(x, y, ...)

Arguments

x

X coordinate vectors of points to join.

y

Y coordinate vectors of points to join.

...

Further graphical parameters.