title: Python - Function "which" from R in Python
body: <p>I'm looking for the equivalent function in R "which" in python. Does anybody know how to adapt it?</p>
  
  <p>For example: </p>
  
  <pre><code>set_false_over &lt;- length(datapoints[which(labels==FALSE &amp; datapoints&gt;=unique_values[i])])
  </code></pre>