File tree 1 file changed +3
-3
lines changed
1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change 7
7
from datetime import datetime, timedelta, time
8
8
import numpy as np
9
9
import pandas as pd
10
- from pandas import datetools
10
+ from pandas import offsets
11
11
np.random.seed(123456 )
12
12
randn = np.random.randn
13
13
randint = np.random.randint
@@ -1223,7 +1223,7 @@ The shift method accepts an ``freq`` argument which can accept a
1223
1223
1224
1224
.. ipython :: python
1225
1225
1226
- ts.shift(5 , freq = datetools.bday )
1226
+ ts.shift(5 , freq = offsets.BDay() )
1227
1227
ts.shift(5 , freq = ' BM' )
1228
1228
1229
1229
Rather than changing the alignment of the data and the index, ``DataFrame `` and
@@ -1246,7 +1246,7 @@ around ``reindex`` which generates a ``date_range`` and calls ``reindex``.
1246
1246
1247
1247
.. ipython :: python
1248
1248
1249
- dr = pd.date_range(' 1/1/2010' , periods = 3 , freq = 3 * datetools.bday )
1249
+ dr = pd.date_range(' 1/1/2010' , periods = 3 , freq = 3 * offsets.BDay() )
1250
1250
ts = pd.Series(randn(3 ), index = dr)
1251
1251
ts
1252
1252
ts.asfreq(BDay())
You can’t perform that action at this time.
0 commit comments