df.groupby(...).apply(<function>) changed between 0.11 and now
This code was working in 0.11 but not anymore in newer versions:

```
>>> import pandas as pd
>>> import numpy as np
>>> print(pd.__version__)
0.11.0
>>> df = pd.DataFrame(np.random.rand(20,4), columns=["a","b","c","d"])
>>> df["group"] = ['a', 'b', 'c', 'd'] * 5
>>> def _top10cites(group):
...         m = group['a'].quantile(q=0.9)
...         return (group['a'] >= m).astype(int)
...
>>> df[["a","c","group"]].groupby("group").apply(_top10cites)
0     0
1     0
2     0
3     0
4     0
5     1
6     1
7     0
8     0
9     0
10    0
11    0
12    1
13    0
14    0
15    0
16    0
17    0
18    0
19    1
Name: a, dtype: int32
```

Newer versions output:

```
0.13.1-489-g7ffa655
Out[39]: 
a      0   4   8   12  16
group                    
a       0   0   0   1   0
b       0   1   0   0   0
c       0   0   0   0   1
d       0   0   1   0   0

[4 rows x 5 columns]
```
