title: limiting the data to the desired values
body: <p>I have a code plotting the lines in the image on left hand side above. I would like to select an area (a rectangular showed on the right side of the image above) and figure out which lines corresponds within that area.</p>
  
  <p>The code plots the image on left is:</p>
  
  <pre><code>datfiles = glob.glob("*.dat")
  for asc_filename in datfiles:
      data = pylab.loadtxt(asc_filename)
      x, y = data[:,0], data[:,3]
      pylab.plot(x, y)
  
  plt.legend()
  pylab.savefig('ts.png')
  </code></pre>
  
  <p>Which modules you would suggest for python and any ideas on where to start with the code?</p>
  
  <p>Thanks!</p>