title: Get maximum weight by unique person with pandas
body: <p>I have this data:</p>
  <pre><code>data = {'name':['dave','bob','barry','bob','dave','barry'],
          'age':[35,30,41,50,44,53],
          'weight':[144,158,150,187,250,197]}
  </code></pre>
  <p>I want to grab the heaviest person by weight for each name - so I only want barry to appear once with an of 53 and his weight of 197 as this barry combination is heavier than 41 age barry.</p>
  <p>I can get it working but not return back the column of weight - here's the full code:</p>
  <pre><code>import pandas as pd
  
  data = {'name':['dave','bob','barry','bob','dave','barry'],
          'age':[35,30,41,50,44,53],
          'weight':[144,158,150,187,250,197]}
  
  
  df = pd.DataFrame(data)
  
  print(df.groupby('name')['age'].max())
  </code></pre>
  <p>So, I get back this as my output:</p>
  <p>name
  barry    53
  bob      50
  dave     44
  Name: age, dtype: int64</p>
  <p>I have tried this this:</p>
  <pre><code>print(df.groupby('name')['age'].max())('weight')
  </code></pre>
  <p>but it doesn't work. I need it in the right order, name, age, weight.</p>
  <p>Thanks in advance</p>