KeyError using custom agg function
Hi,

Suppose I have a dataframe of some stock price where the column 'Open' is the 0th column and 'Close' is the 3rd column. Suppose further that I want to find the maximum difference between Close and Open price. That can be done easily without using the agg method, but let me show what the error is when I use them.

```
!pip install quandl
import quandl
df = quandl.get("WIKI/AAPL", start_date="2006-12-25")

def daily_value(df):
    df.iloc[:, 0] = df.iloc[:,3] - df.iloc[:, 0]
    return df.max()

def daily_value(df):
    df['Open'] = df['Close'] - df['Open']
    return df.max()

display(daily_value(df))
df.agg(dailly_value)
```

Both work as to replace the 0th column, namely 'Open', and return the maximum difference between Open and Close.
This works fine when I have df1 and I type daily_value(df1).

However, when I try df1.agg(daily_value), both version fail. The first says IndexingError: Too many indexers while the latter say KeyError: Close.

How do I proceed if I indeed need to pass the function into *.agg method?

Thanks very much!