For example, I have a few lines with similar coordinates:
import matplotlib.pyplot as plt
x1 = [-1, 0, 1, 1, 1, 0, -1, -1, 0, 0, 1]
x2 = x1[:]
plt.pyplot(x1, color='red')
plt.pyplot(x2, color='green')
plt.show()
Of course it will show graph with only one orange line combined colors. Is there any way (matplotlib function or some approach) to make a small shift of second line to get nice graph(lines close to each other)?
P.S. In my real problem I need to draw graph 10 lines with y-values(0, -1, 1) so the lines frequently overlapped. And I want to add some space between them.
Thanks in advance.