Issue 1:
I just upgraded my projects from pandas 0.16.2 to pandas 0.18.1, but I have a difference on some DataFrame.resample operations, with Weekly frequencies.

For instance, I want to resample daily data to weekly data (W-SUN), and apply an offset to the results, so each row will be a MONDAY and not a SUNDAY.

Code Sample

import pandas as pd
from datetime import timedelta
offset = +timedelta(days=1)

dates = pd.date_range("2001-01-01", freq="D", periods=18)]
a=pd.DataFrame(data=list(range(18)), columns=["value"], index=[dates])

a.resample("1W", how={"value": "sum"}, loffset=offset, closed="right", label="right")

Problem description

With pandas 0.16.2, I got this correct output:

value
2001-01-08 21
2001-01-15 70
2001-01-22 62

ie, each row is a weekly aggregation of the data, and each date is a MONDAY

Resulting index is as follow:

a.index[0]
Timestamp('2001-01-08 00:00:00', offset='W-MON')

However, with pandas 0.18.1, I got this output:

value
2001-01-07 21
2001-01-14 70
2001-01-21 62

each row is correctly aggregated, but the dates are SUNDAYs

Resulting index is as follow:

a.index[0]
Timestamp('2001-01-07 00:00:00', offset='W-SUN')

It's like the loffset parameter is not correctly taken into account in the new DataFrame.resample() implementation.

ie, the output with pandas 0.18.1 is the same as the one using pandas 0.16.2, but calling a.resample("1W", how={"value": "sum"}, loffset=None, closed="right", label="right")

Output of pd.show_versions()

pandas 0.16.1 installation:

INSTALLED VERSIONS
------------------
commit: None
python: 3.4.5.final.0
python-bits: 64
OS: Linux
OS-release: 3.13.0-106-generic
machine: x86_64
processor: x86_64
byteorder: little
LC_ALL: None
LANG: en_US.UTF-8

pandas: 0.16.2
nose: 1.3.7
Cython: 0.22.1
numpy: 1.10.1
scipy: 0.16.0
statsmodels: 0.6.1
IPython: 3.2.1
sphinx: 1.3.1
patsy: 0.3.0
dateutil: 2.4.2
pytz: 2015.7
bottleneck: 1.0.0
tables: 3.2.1
numexpr: 2.4.3
matplotlib: 1.5.0
openpyxl: 2.3.2
xlrd: 0.9.3
xlwt: 1.0.0
xlsxwriter: 0.7.3
lxml: 3.4.4
bs4: 4.3.2
html5lib: None
httplib2: None
apiclient: None
sqlalchemy: 1.0.7
pymysql: 0.6.6.None
psycopg2: None

pandas 0.18.2 installation:

INSTALLED VERSIONS
------------------
commit: None
python: 3.4.5.final.0
python-bits: 64
OS: Linux
OS-release: 4.4.0-57-generic
machine: x86_64
processor: x86_64
byteorder: little
LC_ALL: None
LANG: en_US.UTF-8

pandas: 0.18.1
nose: 1.3.7
pip: 9.0.1
setuptools: 27.2.0
Cython: 0.22.1
numpy: 1.10.4
scipy: 0.16.0
statsmodels: 0.6.1
xarray: None
IPython: 3.2.1
sphinx: 1.3.1
patsy: 0.3.0
dateutil: 2.4.2
pytz: 2015.6
blosc: None
bottleneck: 1.0.0
tables: 3.2.1
numexpr: 2.6.0
matplotlib: 1.4.3
openpyxl: 2.3.2
xlrd: 0.9.3
xlwt: 1.0.0
xlsxwriter: 0.7.3
lxml: 3.4.4
bs4: 4.3.2
html5lib: None
httplib2: None
apiclient: None
sqlalchemy: 1.0.7
pymysql: 0.6.6.None
psycopg2: None
jinja2: 2.7.3
boto: None
pandas_datareader: None

Issue 2:
Code Sample, a copy-pastable example if possible

# Create DF
df = pd.DataFrame(np.random.rand(5,2), columns=list('AB'), index=pd.date_range('2010-01-01 09:00:00', periods=5, freq='s'))

print(df)
A B
2010-01-01 09:00:00 0.283113 0.559642
2010-01-01 09:00:01 0.754942 0.621557
2010-01-01 09:00:02 0.102002 0.892100
2010-01-01 09:00:03 0.885400 0.524359
2010-01-01 09:00:04 0.324761 0.706758

#Resample, loffset works fine using mean(), is offset by 2 hours.
print(df.resample('2s', loffset='2h').mean())
A B
2010-01-01 11:00:00 0.519028 0.590599
2010-01-01 11:00:02 0.493701 0.708229
2010-01-01 11:00:04 0.324761 0.706758

# Resample with agg(), loffset doesn't work anymore.
print(df.resample('2s', loffset='2h').agg(dict(A='sum', B='mean')))
A B
2010-01-01 09:00:00 1.038055 0.590599
2010-01-01 09:00:02 0.987402 0.708229
2010-01-01 09:00:04 0.324761 0.706758

Expected Output

I'd expect the same as with mean(), this is how resample worked in the past with resample(how=...).

But maybe I also misunderstood something about the change. If so please enlighten me.

Since I need this to keep things going, I use the following workaround for now, please let me know if this is the way to go or if there's a more efficient way:

print(df.resample('2s', loffset='2h').agg(dict(A='sum', B='mean')).tshift(2, 'h'))

output of pd.show_versions()

INSTALLED VERSIONS

commit: None

python: 3.5.1.final.0

python-bits: 64

OS: Darwin

OS-release: 15.5.0

machine: x86_64

processor: i386

byteorder: little

LC_ALL: None

LANG: de_DE.UTF-8

pandas: 0.18.1

nose: 1.3.7

pip: 8.1.2

setuptools: 20.3

Cython: 0.23.4

numpy: 1.10.4

scipy: 0.17.1

statsmodels: 0.6.1

xarray: None

IPython: 4.2.0

sphinx: 1.3.5

patsy: 0.4.0

dateutil: 2.5.1

pytz: 2016.2

blosc: None

bottleneck: 1.0.0

tables: 3.2.2

numexpr: 2.5.2

matplotlib: 1.5.1

openpyxl: 2.3.2

xlrd: 0.9.4

xlwt: 1.0.0

xlsxwriter: 0.8.4

lxml: 3.6.0

bs4: 4.4.1

html5lib: None

httplib2: None

apiclient: None

sqlalchemy: 1.0.12

pymysql: None

psycopg2: None

jinja2: 2.8

boto: 2.39.0

pandas_datareader: 0.2.1

In [92]: