title: Group and display rows based on column values in r
body: <p><a href="https://i.stack.imgur.com/KO7zT.png" rel="nofollow noreferrer">enter image description here</a></p>
  
  <p>I want to group the rows based on the column "Rating" and then display the rows in each group which has the max One_Year_Return. I am new to R and not able to write the code. Appreciate any help on this.</p>