title: Selecting subset of elements of an array/list with boolean indices
body: <p>I have a list (or numpy array), let's call it <code>my_list</code> with length of <code>100</code>. I have another list, called <code>flag_list</code> with the same length consisting of 1s and 0s. I want my <code>new_list</code> be the elements of <code>my_list</code> whom have 1 in their corresponding position in flag_list. Somehow, to remove those who have 0 flag.</p>
  <p>Is there a short way of doing this without writing a for loop?</p>
  <p>I also have a 2d numpy array that I want to exclude some raws based on flags.</p>
  <p>Thanks in advane</p>