How to plot in different colors in Matplotlib
===

I'm new to Matplotlib. I have the position of a person every second, and I am trying to make a graph showing this. I have managed to show it, but now I would like it to display different colors according to their speed. So, I need the plt.plot() color to depend on the distance between each pair of points, instead of being always the same.
Does anyone know how to do this? 
Thank you!