title: Panda contains formula with replace
body: <p>I cant get if statement to work on 2 columns</p>
  
  <p>Progress so far:</p>
  
  <pre><code>col1= example.com/abc/abs
  </code></pre>
  
  <p>Goal: to get output of the whats after last <code>"/"</code></p>
  
  <p>This worked:</p>
  
  <pre><code>df['col2'] = df['col1'].str.rsplit('/', 1, expand=True)[1]
  </code></pre>
  
  <p>I need help with this part:</p>
  
  <p>If col2 contains <code>"/"</code>, then I want to replace col1 with it, otherwise leave col1 as is.</p>
  
  <p>I tried but did not work:</p>
  
  <pre><code>df1['col1'] = np.where(df1['col2'] =="/" , df1['col2'], df1['col1'])
  </code></pre>