title: Pandas : OR If value contains "-" then do
body: <p>I have the following code (translated):</p>
  
  <pre><code>m1 = df['stock']&gt;=1
  m2 = (df['stock']==0) &amp; (df['date'].notna())
  df['deliverytime'] = np.select([m1, m2], ['2-4 days', df['date']], 'unknown')
  </code></pre>
  
  <p>So that means: when stock is above 0 (1), then get 2-4 days, otherwise, check the date, and if stock is for example 0, and there is no date, then there will be 'unknown'. </p>
  
  <p>Now the following; the supplier has also added negative stock values, example: -10, -5 etc.</p>
  
  <p>I would like to modify "m2", so that it says: stock = 0, stock has "-" sign, and date is not empty THEN do.. </p>
  
  <p>What is the best way to do that?</p>
  
  <p>Thanks!</p>
  
  <p>-- edit - simple dataframe --</p>
  
  <pre><code>stock,date
  2,9-9-2019
  -4,9-9-2019
  </code></pre>