title: Fill values in rows of a column based on a condition applied to another column in a data frame
body: <p>I have a simple doubt,say I have a data frame called df</p>
  
  <p>Structure:</p>
  
  <pre><code>ID   col1   col2  col3   status
  1    1      A            Unmapped
  2    2            X      Unmapped
  3           C     Q      Unmapped
  4                 S      Unmapped
  5    4      E            Unmapped
  </code></pre>
  
  <p>I want to fill values in column 'status' based on condition. The condition is if for 1st row in col1 is not equal to blank then 1st row in column status must be 'mapped_one'. If col1 is blank then it must check if row under col2 is not blank, then status must be 'mapped_two' so on and so forth</p>
  
  <p>Expected output:</p>
  
  <pre><code>ID   col1   col2  col3   status
  1    1      A            mapped_one
  2    2            X      mapped_one
  3           C     Q      mapped_two
  4                 S      mapped_three
  5    4      E            mapped_one
  </code></pre>
  
  <p>This is what I tired but this didn't work, all rows were assigned the same value</p>
  
  <pre><code> df.loc[df.col1 != "    ", 'status'] = "mapped_one"
  </code></pre>
  
  <p>Thanks in advance</p>