23 May 2016

computational tools

  1. statistical functions

    1. percent change

    2. covariance

    3. correlation

    4. data ranking

  2. window functions

    1. summary

       s = pd.Series(np.random.randn(1000), index=pd.date_range('1/1/2000', periods=1000))
       s = s.cumsum()
      
       r = s.rolling(window=60)
       # r.agg         r.apply       r.count       r.exclusions  r.max         r.median      r.name        r.skew        r.sum
       # r.aggregate   r.corr        r.cov         r.kurt        r.mean        r.min         r.quantile    r.std         r.var
      
       r.mean()
      
    2. rolling windows

    3. centering windows

    4. binary window functions

    5. computing rolling pairwise covariance and correlation

  3. aggregation

    1. applying multiple functions at once

    2. applying differenct functions to df columns

  4. expanding windows

  5. exponentially weighted windows

reference

  1. rolling window demo


blog comments powered by Disqus