Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion doc/source/computation.rst
Original file line number Diff line number Diff line change
Expand Up @@ -323,7 +323,7 @@ compute the mean absolute deviation on a rolling basis:

mad = lambda x: np.fabs(x - x.mean()).mean()
@savefig rolling_apply_ex.png
s.rolling(window=60).apply(mad).plot(style='k')
s.rolling(window=60).apply(mad, raw=True).plot(style='k')

.. _stats.rolling_window:

Expand Down
2 changes: 1 addition & 1 deletion doc/source/cookbook.rst
Original file line number Diff line number Diff line change
Expand Up @@ -496,7 +496,7 @@ Unlike agg, apply's callable is passed a sub-DataFrame which gives you access to
def Red(x):
return functools.reduce(CumRet,x,1.0)

S.expanding().apply(Red)
S.expanding().apply(Red, raw=True)


`Replacing some values with mean of the rest of a group
Expand Down