title: Bad merge syntax in Python? f() takes 1 positional argument but 2 were given
body: <p>I am trying the following:</p>
  <pre><code>df2.groupby(['A']).max('Delta')
  </code></pre>
  <p>And getting this error:</p>
  <pre><code>f() takes 1 positional argument but 2 were given
  </code></pre>
  <p>Added context: That snippet is from the following fuller code works fine in my ipynb (Python 3) but not in an embedded script also using Python v3.</p>
  <pre><code>df3 = df2.merge(df2.groupby(['A']).max('Delta').reset_index()[['A','Delta']],how='left',on='A',suffixes=(&quot;&quot;,&quot;_max&quot;)).merge(df2.groupby(['A']).min('Delta').reset_index()[['A','Delta']],how='left',on='A',suffixes=(&quot;&quot;,&quot;_min&quot;))
  </code></pre>
  <p>I've also tried:</p>
  <pre><code>df2.groupby(['A']).max(['Delta'])
  </code></pre>