title: Select certain rows (condition met), but only some columns in Python/Numpy
body: <p>I have an numpy array with 4 columns and want to select columns 1, 3 and 4, where the value of the second column meets a certain condition (i.e. a fixed value). I tried to first select only the rows, but with all 4 columns via:</p>
  <pre><code>I = A[A[:,1] == i]
  </code></pre>
  <p>which works. Then I further tried (similarly to matlab which I know very well):</p>
  <pre><code>I = A[A[:,1] == i, [0,2,3]]
  </code></pre>
  <p>which doesn't work. How to do it?</p>
  <hr />
  <p><strong>EXAMPLE DATA:</strong></p>
  <pre><code> &gt;&gt;&gt; A = np.array([[1,2,3,4],[6,1,3,4],[3,2,5,6]])
   &gt;&gt;&gt; print A
   [[1 2 3 4]
    [6 1 3 4]
    [3 2 5 6]]
   &gt;&gt;&gt; i = 2
       
   # I want to get the columns 1, 3 and 4 
   # for every row which has the value i in the second column. 
   # In this case, this would be row 1 and 3 with columns 1, 3 and 4:
   [[1 3 4]
    [3 5 6]]
   
  </code></pre>
  <p>I am now currently using this:</p>
  <pre><code>I = A[A[:,1] == i]
  I = I[:, [0,2,3]]
  </code></pre>
  <p>But I thought that there had to be a nicer way of doing it... (I am used to MATLAB)</p>