-
-
Notifications
You must be signed in to change notification settings - Fork 18.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
df.groupby('symbol')['status'].ffill() results in Exception: cannot handle a non-unique multi-index! #19437
Labels
Comments
gregsifr
changed the title
Exception: cannot handle a non-unique multi-index!
df.groupby('symbol')['status'].ffill() results in Exception: cannot handle a non-unique multi-index!
Jan 29, 2018
This could be a bit of work to fix, given the current implementation of |
This was referenced Jan 31, 2018
3 tasks
This looks to work on master. Could use a test.
|
mroeschke
added
good first issue
Needs Tests
Unit test(s) needed to prevent regressions
and removed
Difficulty Intermediate
Groupby
Reshaping
Concat, Merge/Join, Stack/Unstack, Explode
labels
Oct 15, 2019
5 tasks
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Code Sample, a copy-pastable example if possible
Raised exception
Problem description
Performing
ffill()
does not forward fill values as intended. The index has duplicate values, the expectation is that the values will be filled according to the order the rows are in already.Duplicate index values are possible when using high frequency time intervals.
Expected Output
Output of
pd.show_versions()
INSTALLED VERSIONS
commit: None
python: 2.7.14.final.0
python-bits: 64
OS: Linux
OS-release: 4.13.0-31-generic
machine: x86_64
processor: x86_64
byteorder: little
LC_ALL: None
LANG: en_AU.UTF-8
LOCALE: None.None
pandas: 0.22.0
pytest: 3.2.1
pip: 9.0.1
setuptools: 36.5.0.post20170921
Cython: 0.26.1
numpy: 1.14.0
scipy: 0.19.1
pyarrow: None
xarray: None
IPython: 5.4.1
sphinx: 1.6.3
patsy: 0.4.1
dateutil: 2.6.1
pytz: 2017.3
blosc: None
bottleneck: 1.2.1
tables: 3.4.2
numexpr: 2.6.2
feather: None
matplotlib: 2.1.0
openpyxl: 2.4.8
xlrd: 1.1.0
xlwt: 1.3.0
xlsxwriter: 1.0.2
lxml: 4.1.0
bs4: 4.6.0
html5lib: 0.999999999
sqlalchemy: 1.1.13
pymysql: None
psycopg2: 2.7.3.2 (dt dec pq3 ext lo64)
jinja2: 2.9.6
s3fs: None
fastparquet: None
pandas_gbq: None
pandas_datareader: None
This also happens with
axis=1
.The text was updated successfully, but these errors were encountered: