question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

MultiIndex.is_monotonic_increasing

See original GitHub issue

This does not seem to be documented anywhere. For MultiIndex, how is .is_monotonic_increasing different from .is_lexsorted?

Issue Analytics

  • State:open
  • Created 4 years ago
  • Comments:9 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
MarcoGorellicommented, Feb 28, 2020

Does that mean MultiIndex.sortlevel will also only be sorting the codes, rather than values?

By looking at the source code, that seems to be the case.

This would be rather confusing and will not be useful for users …

If I’ve understood is_lexsorted and sortlevel correctly, I agree.

Might want to keep an eye on the thread in #32312

1reaction
MarcoGorellicommented, Feb 27, 2020

Does it mean anything or just not accurate?

Given the bug you uncovered in #32259, at the moment I’d say it’s more accurate 😃

Read more comments on GitHub >

github_iconTop Results From Across the Web

pandas.MultiIndex.is_monotonic_increasing
MultiIndex.is_monotonic_increasing¶. MultiIndex. is_monotonic_increasing ¶. return if the index is monotonic increasing (only equal or increasing) values.
Read more >
pandas/multi.py at main - GitHub
This class manages a MultiIndex by mapping label combinations to positive. integers. ... monotonic decreasing if and only if reverse is monotonic increasing....
Read more >
pandas.Index — pandas 1.0.0rc0+132.ga4b2c8db9 ...
Return if the index is monotonic increasing (only equal or increasing) values. is_unique. Return if the index has unique values.
Read more >
How can I check if a Pandas dataframe's index is sorted
Just for the sake of completeness, this would be the procedure to check whether the dataframe index is monotonic increasing and also unique, ......
Read more >
Working with MultiIndex in pandas DataFrame
Create MultiIndex pandas DataFrame (Multi level Index). A multi-level index DataFrame is a type of DataFrame that contains multiple level or ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found