As we know, if we want to give color to a point, we should do this.
import matplotlib.pyplot as plt
plt.plot(arrayOfX, arrayOfY, 'o', markersize=5, color = '0.0')
And I will get a picture with lots of black points.
What I want to do is I want every point with different color.
The syntax below is not correct, but can describe what I want to do:
plt.plot(arrayOfX, arrayOfY, 'o', markersize=5, color = color_list)
where the color_list
contains every point's color.
Now I have an idea like this:
for i, color in enumerate(color_list):
plt.plot(array(arrayOfX[i]), array(arrayOfY[i]), 'o', markersize=5, color = str(color))
which is extremely stupid but workable...
I might need a more elegant solution. Thank you all!