triqs.plot.protocol.clip_array

triqs.plot.protocol.clip_array(x_array, x_min, x_max)[source]
Given:
  • x_array a 1d numpy array of shape (L), of ordered values or in fact any generator of ordered values.

  • x_min, x_max

it returns the slice sl such that
  • x_array[sl] is in [x_min, x_max]