Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Next Next commit
DOC: Fixing even more warnings (not many left)
  • Loading branch information
Marc Garcia committed Jun 14, 2019
commit c396d44a23fc485cb0a1994cd12dc44582e3e796
6 changes: 2 additions & 4 deletions doc/source/index.rst.template
Original file line number Diff line number Diff line change
Expand Up @@ -38,8 +38,7 @@ See the :ref:`overview` for more detail about what's in the library.
:maxdepth: 3
:hidden:
{% endif %}

{% if not single_doc -%}
{% if not single_doc %}
What's New in 0.25.0 <whatsnew/v0.25.0>
install
getting_started/index
Expand All @@ -52,8 +51,7 @@ See the :ref:`overview` for more detail about what's in the library.
{% if not single_doc -%}
development/index
whatsnew/index
{% endif -%}

{% endif %}

* :doc:`whatsnew/v0.25.0`
* :doc:`install`
Expand Down
2 changes: 1 addition & 1 deletion doc/source/whatsnew/v0.17.1.rst
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ We can render the HTML to get the following table.
:file: whatsnew_0171_html_table.html

:class:`~pandas.core.style.Styler` interacts nicely with the Jupyter Notebook.
See the :ref:`documentation </style.ipynb>` for more.
See the :ref:`documentation </user_guide/style.ipynb>` for more.

.. _whatsnew_0171.enhancements:

Expand Down
4 changes: 2 additions & 2 deletions doc/source/whatsnew/v0.20.0.rst
Original file line number Diff line number Diff line change
Expand Up @@ -387,7 +387,7 @@ For example, after running the following, ``styled.xlsx`` renders as below:
import os
os.remove('styled.xlsx')

See the :ref:`Style documentation </style.ipynb#Export-to-Excel>` for more detail.
See the :ref:`Style documentation </user_guide/style.ipynb#Export-to-Excel>` for more detail.

.. _whatsnew_0200.enhancements.intervalindex:

Expand Down Expand Up @@ -497,7 +497,7 @@ Other Enhancements
- ``DataFrame.to_excel()`` has a new ``freeze_panes`` parameter to turn on Freeze Panes when exporting to Excel (:issue:`15160`)
- ``pd.read_html()`` will parse multiple header rows, creating a MutliIndex header. (:issue:`13434`).
- HTML table output skips ``colspan`` or ``rowspan`` attribute if equal to 1. (:issue:`15403`)
- :class:`pandas.io.formats.style.Styler` template now has blocks for easier extension, see the :ref:`example notebook </style.ipynb#Subclassing>` (:issue:`15649`)
- :class:`pandas.io.formats.style.Styler` template now has blocks for easier extension, see the :ref:`example notebook </user_guide/style.ipynb#Subclassing>` (:issue:`15649`)
- :meth:`Styler.render() <pandas.io.formats.style.Styler.render>` now accepts ``**kwargs`` to allow user-defined variables in the template (:issue:`15649`)
- Compatibility with Jupyter notebook 5.0; MultiIndex column labels are left-aligned and MultiIndex row-labels are top-aligned (:issue:`15379`)
- ``TimedeltaIndex`` now has a custom date-tick formatter specifically designed for nanosecond level precision (:issue:`8711`)
Expand Down
2 changes: 1 addition & 1 deletion doc/source/whatsnew/v0.25.0.rst
Original file line number Diff line number Diff line change
Expand Up @@ -283,7 +283,7 @@ of ``object`` dtype. :attr:`Series.str` will now infer the dtype data *within* t
s
s.str.startswith(b'a')

.. _whatsnew_0250.api_breaking.incompatible_index_unions
.. _whatsnew_0250.api_breaking.incompatible_index_unions:

Incompatible Index Type Unions
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Expand Down
12 changes: 12 additions & 0 deletions pandas/core/indexes/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -1411,6 +1411,9 @@ def rename(self, name, inplace=False):

@property
def nlevels(self):
"""
Number of levels.
"""
return 1

def _sort_levels_monotonic(self):
Expand Down Expand Up @@ -1740,6 +1743,9 @@ def is_mixed(self):
return self.inferred_type in ['mixed']

def holds_integer(self):
"""
Whether the type is an integer type.
"""
return self.inferred_type in ['integer', 'mixed-integer']

@cache_readonly
Expand Down Expand Up @@ -3966,6 +3972,9 @@ def _is_memory_usage_qualified(self):
return self.is_object()

def is_type_compatible(self, kind):
"""
Whether the index type is compatible with the provided type.
"""
return kind == self.inferred_type

_index_shared_docs['contains'] = """
Expand Down Expand Up @@ -4338,6 +4347,9 @@ def sort_values(self, return_indexer=False, ascending=True):
return sorted_index

def sort(self, *args, **kwargs):
"""
Use sort_values instead.
"""
raise TypeError("cannot sort an Index object in-place, use "
"sort_values instead")

Expand Down