title: filter on one column and rank on another without grouping in dataframe
body: <p>I have a data frame having 4 columns student_name, total_marks, is_shortlisted, rank</p>
  
  <p>I wanted to rank rows on the basis of the total_marks column where the is_shortlisted = "Y".</p>
  
  <p>sample input data : </p>
  
  <pre><code>name     total_marks   is_shortlisted
  Aman       67              Y
  Nitin      89              Y
  Ankur      76              Y
  Mohit      56              N
  Ashish     64              Y
  </code></pre>
  
  <p>sample output data : </p>
  
  <pre><code>name     total_marks   is_shortlisted  rank 
  Aman       67              Y            3
  Nitin      89              Y            1
  Ankur      76              Y            2
  Mohit      56              N            nan
  Ashish     64              Y            4
  </code></pre>