title: If ElseIf Else condition in pandas dataframe list comprehension
body: <p>I have a dataframe with 11 columns: Status1-Status5, Time1-Time5 &amp; Time_Min</p>
  
  <pre><code>df = pd.DataFrame([[100,200,150,400,500,'a','b','a','c','a',100], [300,400,200,500,250,'b','b','c','c','c',200]], columns=['TIME_1', 'TIME_2', 'TIME_3', 'TIME_4', 'TIME_5','STATUS_1','STATUS_2','STATUS_3','STATUS_4','STATUS_5','TIME_MIN'])
  </code></pre>
  
  <p>I would like to reproduce a code I have in SAS currently which does the following</p>
  
  <pre><code>IF TIME_1 = TIME_MIN THEN STATUS = STATUS_1;
  ELSE IF TIME_2 = TIME_MIN THEN STATUS = STATUS_2;
  ELSE IF TIME_3 = TIME_MIN THEN STATUS = STATUS_3;
  ELSE IF TIME_4 = TIME_MIN THEN STATUS = STATUS_4;
  ELSE STATUS = STATUS_5;
  </code></pre>
  
  <p>Expected output for column STATUS would be</p>
  
  <pre><code>['a','c']
  </code></pre>
  
  <p>I tried building something along these lines (which would need to be extended with else ifs)</p>
  
  <pre><code>df['STATUS'] = [a if x == y else b for x,y,a,b in df[['TIME_MIN','TIME_1','STATUS_1','STATUS_2']]]
  </code></pre>
  
  <p>But this just gives an error. I'm sure it's a simple fix, but I can't quite figure it out. </p>