title: How to mask numpy structured array on multiple columns?
body: <p>I have a numpy structured array with a dtype such as:</p>
  
  <pre><code>A = numpy.empty(10, dtype=([('segment', '&lt;i8'), ('material', '&lt;i8'), ('rxN', '&lt;i8')]))
  </code></pre>
  
  <p>I know I can create a mask such as:</p>
  
  <pre><code>A[A['segment'] == 42] = ...
  </code></pre>
  
  <p>Is there a way to create a mask on multiple columns? For example (I know this doesn't work, but I wish it did):</p>
  
  <pre><code>A[A['segment'] == 42 and A['material'] == 5] = ...
  </code></pre>