import random # note that matplotlib requires 2d array for rbg colors rgb = [[random.random(), random.random(), random.random()]] plt.scatter(x, y, c=rgb)