title: Get value from another df based on condition
body: <p>I have 2 df</p>
  <p>df1:</p>
  <pre><code>ID       X Y Cond
  Johnson  2 3 fine
  Sand     NAN NAN sick
  Cooper   1 2 fine
  Nelson   1 2 fine
  Peterson 4 5 fine
  </code></pre>
  <p>and df2 :</p>
  <pre><code>id2      X Y 
  Magic    2 3 
  Sand     2 3 
  Cooper   1 2 
  Dean     1 2 
  </code></pre>
  <p>I want to update x value in df1, if Cond =&quot;sick&quot; and df[&quot;id&quot;] = df[&quot;id2]
  to get the new df1 :</p>
  <pre><code>ID       X Y Cond
  Johnson  2 3 fine
  Sand     2 3  sick
  Cooper   1 2 fine
  Nelson   1 2 fine
  Peterson 4 5 fine
  </code></pre>
  <p>I tried :</p>
  <pre><code>df1[&quot;x&quot;] = np.where((df[&quot;cond&quot;]==&quot;sick&quot;)&amp; (df1[&quot;id&quot;]==df2[&quot;id2&quot;]),df2[&quot;x&quot;],&quot;&quot;)
  </code></pre>
  <p>But its not working. I get this ValueError :</p>
  <pre><code>ValueError: Can only compare identically-labeled Series objects
  
  </code></pre>
  <p>Thank you</p>