Connecting the Dots with Scatter Plot (Motion Jumps)

I have a bunch of (x,y) points that relate to an ordered path of a meteor; however, when plotted they may no become ordered. For example, (0,0), (2,2), (1,1), (3,4) ... Point 2 jumps backwards. I'd like to connect the points with a line, or better, a line with an arrow indicating direction, so when someone looks at the plot, they can see how uneven the path is and any possible wild jumps in the direction. For example, (0,0), (0.5, 11), (1,1), (2,2) ... Can this be dome?

···

--
My life in two words. "Interrupted Projects." -- WTW (quote originator)

Hi,

your problem is that you enter the X values in an unordered way? Then, you
just have to sort the key-value-pairs before plotting.

One way it works is to create a dict in the form "d = {x1: y1,x2:y2}" (with a
for loop and so on), then extract the keys:

k = d.keys()
k.sort()

v = [d[key] for key in k]

... now plot(k,v)

Maybe there is a simpler solution, but this one works.

Regards,
Philipp