@@ -1649,11 +1649,21 @@ def f(x):
1649
1649
1650
1650
self ._check_statistic (self .frame , 'skew' , f )
1651
1651
1652
+ def test_quantile (self ):
1653
+ try :
1654
+ from scipy .stats import scoreatpercentile
1655
+ except ImportError :
1656
+ return
1657
+
1658
+ q = self .tsframe .quantile (0.1 , axis = 0 )
1659
+ self .assertEqual (q ['A' ], scoreatpercentile (self .tsframe ['A' ], 10 ))
1660
+ q = self .tsframe .quantile (0.9 , axis = 1 )
1661
+ q = self .intframe .quantile (0.1 )
1662
+ self .assertEqual (q ['A' ], scoreatpercentile (self .intframe ['A' ], 10 ))
1663
+
1652
1664
def test_cumsum (self ):
1653
1665
cumsum = self .tsframe .cumsum ()
1654
-
1655
1666
assert_series_equal (cumsum ['A' ], np .cumsum (self .tsframe ['A' ].fillna (0 )))
1656
-
1657
1667
df = self .klass ({'A' : np .arange (20 )}, index = np .arange (20 ))
1658
1668
1659
1669
# works
@@ -1673,6 +1683,11 @@ def test_cumprod(self):
1673
1683
cumprod_xs = self .tsframe .cumprod (axis = 1 )
1674
1684
self .assertEqual (np .shape (cumprod_xs ), np .shape (self .tsframe ))
1675
1685
1686
+ def test_describe (self ):
1687
+ desc = self .tsframe .describe ()
1688
+ desc = self .mixed_frame .describe ()
1689
+ desc = self .frame .describe ()
1690
+
1676
1691
if __name__ == '__main__' :
1677
1692
unittest .main ()
1678
1693
0 commit comments