You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The error's pretty opaque and several layers deep, so I don't really understand much about what's going wrong internally. It does work correctly for shift(1), so I assume it's something about negative indices.
Expected Output
df['x'].shift(-1) and df.eval('x.shift(-1)') should have identical output.
I suspect this will be fixed by fixing #16363. I added your example there to ensure that it's tested (we'll reopen this one if the fix turns out to be different).
I think we could use a contributor for this, so feel free to dive in.
Code Sample, a copy-pastable example if possible
Problem description
The error's pretty opaque and several layers deep, so I don't really understand much about what's going wrong internally. It does work correctly for
shift(1)
, so I assume it's something about negative indices.Expected Output
df['x'].shift(-1)
anddf.eval('x.shift(-1)')
should have identical output.Output of
pd.show_versions()
INSTALLED VERSIONS
commit: None
python: 3.5.3.final.0
python-bits: 64
OS: Darwin
OS-release: 16.6.0
machine: x86_64
processor: i386
byteorder: little
LC_ALL: None
LANG: None
LOCALE: en_US.UTF-8
pandas: 0.20.1
pytest: 3.1.1
pip: 9.0.1
setuptools: 28.8.0
Cython: None
numpy: 1.12.1
scipy: None
xarray: None
IPython: None
sphinx: None
patsy: None
dateutil: 2.6.0
pytz: 2017.2
blosc: None
bottleneck: None
tables: None
numexpr: None
feather: None
matplotlib: None
openpyxl: None
xlrd: None
xlwt: None
xlsxwriter: None
lxml: None
bs4: None
html5lib: None
sqlalchemy: None
pymysql: None
psycopg2: None
jinja2: 2.9.6
s3fs: None
pandas_gbq: None
pandas_datareader: None
The text was updated successfully, but these errors were encountered: