Skip to content

Group By datatype screwed when group consists of one value #1065

@gerigk

Description

@gerigk

x = DataFrame(np.arange(9).reshape(3,3))
x['test']=0
x['fl']= [1.3,1.5,1.6]
x.groupby('test').agg({'fl':'sum',2:'size'}).dtypes
Out[]:
2 int64
fl object
(version 0.8)

Output in 0.7.3
Out[]:
2 int64
fl float64

The output for x['test'] = [1,2,3] works fine

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions