h2oai / datatable

A Python package for manipulating 2-dimensional tabular data structures

Home Page:https://datatable.readthedocs.io

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Inconsistent column types returned by `sum()`

oleksiyskononenko opened this issue · comments

>>> from datatable import dt
>>> DT = dt.Frame([1, 2])
>>> DT.sum()
   |      C0
   | float64
-- + -------
 0 |       3
[1 row x 1 column]
>>> DT[:, dt.sum(f[0])]
   |    C0
   | int64
-- + -----
 0 |     3
[1 row x 1 column]

Note, that in the first case the returned column type is float64 while in the second case it is int64. It would be nice to return the same column type in the both cases.

I raised an issue here : #2904

Ah, yes, couldn’t find it. Probably we just need more minimalistic example and the topic should mention sum().

Duplicate of #2904