File tree Expand file tree Collapse file tree 3 files changed +17
-4
lines changed Expand file tree Collapse file tree 3 files changed +17
-4
lines changed Original file line number Diff line number Diff line change @@ -38,7 +38,6 @@ pandas 0.6.1
38
38
is about 3x faster than df[column][row] by handling fewer cases (GH #437)
39
39
- Add Qt table widget to sandbox (PR #435)
40
40
41
-
42
41
**Improvements to existing features **
43
42
44
43
- Improve memory usage of `DataFrame.describe ` (do not copy data
@@ -49,6 +48,7 @@ pandas 0.6.1
49
48
- Exclude non-numeric types in DataFrame.{corr, cov}
50
49
- Override Index.astype to enable dtype casting (GH #412)
51
50
- Use same float formatting function for Series.__repr__ (PR #420)
51
+ - Use available console width to output DataFrame columns (PR #453)
52
52
53
53
**Bug fixes **
54
54
@@ -62,6 +62,7 @@ pandas 0.6.1
62
62
- Fix groupby exception raised with as_index=False and single column selected
63
63
(GH #421)
64
64
- Implement DateOffset.__ne__ causing downstream bug (GH #456)
65
+ - Fix __doc__-related issue when converting py -> pyo with py2exe
65
66
66
67
Thanks
67
68
------
Original file line number Diff line number Diff line change @@ -2054,8 +2054,12 @@ def unstack(self, level=-1):
2054
2054
from pandas .core .reshape import unstack
2055
2055
if isinstance (level , (tuple , list )):
2056
2056
result = self
2057
- for lev in level :
2057
+ to_unstack = level
2058
+ while to_unstack :
2059
+ lev = to_unstack [0 ]
2058
2060
result = unstack (result , lev )
2061
+ to_unstack = [other - 1 if other > lev else other
2062
+ for other in to_unstack [1 :]]
2059
2063
return result
2060
2064
else :
2061
2065
return unstack (self , level )
Original file line number Diff line number Diff line change @@ -469,8 +469,16 @@ def test_stack_unstack_multiple(self):
469
469
restacked = restacked .sortlevel (0 )
470
470
471
471
assert_frame_equal (restacked , self .ymd )
472
- self .assertEquals (restacked .index .names ,
473
- self .ymd .index .names )
472
+ self .assertEquals (restacked .index .names , self .ymd .index .names )
473
+
474
+ # GH #451
475
+ unstacked = self .ymd .unstack ([1 , 2 ])
476
+ expected = self .ymd .unstack (1 ).unstack (1 )
477
+ assert_frame_equal (unstacked , expected )
478
+
479
+ unstacked = self .ymd .unstack ([2 , 1 ])
480
+ expected = self .ymd .unstack (2 ).unstack (1 )
481
+ assert_frame_equal (unstacked , expected )
474
482
475
483
def test_groupby_transform (self ):
476
484
s = self .frame ['A' ]
You can’t perform that action at this time.
0 commit comments