wesm/pandas — Issue #252: Casting float column to int does not work
Author: wesm
Created: 2011-10-18 19:36:14+00:00
State: open
Labels: Bug

```

In [1]: df = DataFrame(np.random.randint(0, 5, 10), dtype=float)

In [2]: df
Out[2]:
0
0 1
1 4
2 0
3 0
4 1
5 1
6 2
7 4
8 3
9 3

In [3]: df[0] = df[0].astype('i8')

In [4]: df
Out[4]:
0
0 1
1 4
2 0
3 0
4 1
5 1
6 2
7 4
8 3
9 3

In [5]: df.dtypes
Out[5]:
0 float64
Name: None, Length: 1
```