title: Pandas - Fill Column Values based on conditions on Two other columns
body: <p>I want to fill the values of column 3 based on condition on column 1 and 2 without having to import numpy and use np.where</p>
  
  <p>DataFrame:</p>
  
  <pre><code>1  CNT T
  2  T   T
  3  T   NT
  4  CNT INT
  </code></pre>
  
  <p>Condition:
  if value in Column1 != 'T' and value in Column2 == 'T' then value in Column3 = value in Column1 (='CNT')
  else value in Column3 == value in Column2</p>
  
  <p>Output:</p>
  
  <pre><code>1  CNT  T   CNT
  2  T    T   T
  3  T    NT  NT
  4  CNT  INT INT
  </code></pre>
  
  <p>What I have tried is:</p>
  
  <pre><code>Dataframe[3] = Dataframe.loc[(Dataframe[1] != 'T') &amp; (Dataframe[2] == 'T'), 1]
  </code></pre>
  
  <p>but that creates
  Output:</p>
  
  <pre><code>1  CNT  T   CNT
  2  T    T   NaN
  3  T    NT  NaN
  4  CNT  INT NaN
  </code></pre>