title: Matplotlib python connect two scatter plots with lines for each pair of (x,y) values?
body: <p>I am having trouble connecting two sets of points in a scatter plot with each other such that a line (in this example, using dummy data) connects all the 'pre' points with the corresponding 'post' points. The 'marker = 'o-' argument doesn't work for plt. scatter, but does for plt. plot. Suggestions on how to connect the corresponding values? Thanks and hope this question makes sense!</p>
  
  <pre><code>import matplotlib.pyplot as plt
  import numpy as np
  x1 = ["pre"] * 4
  x2 = ["post"] * 4
  y1 = [0.1, 0.15, 0.13, 0.25]
  y2 = [0.85, 0.76, 0.8, 0.9]
  plt.scatter(x1, y1, color='y')
  plt.scatter(x2, y2, color='g')
  plt.show()
  </code></pre>