DOC: don't include all methods/attributes of IntervalIndex
State: closed

Alternative for #16050 

I totally forgot I already had made such a "class without autosummary table" template before for Categorical, so I hope this should work for IntervalIndex as well.

Labels:
name: Docs

Comments:
@TomAugspurger I hope this fixes the warnings.

Maybe we could also use this for the other Index subclasses like DatetimeIndex, MultiIndex, ... although it would be nice to still have a list of those attributes that are special to them, and to refer to the main Index docstring page for a list of all methods. But not sure if such flexibility is possible with sphinx/jinja (and for a later PR in any case :-))
# [Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/16221?src=pr&el=h1) Report
> Merging [#16221](https://codecov.io/gh/pandas-dev/pandas/pull/16221?src=pr&el=desc) into [master](https://codecov.io/gh/pandas-dev/pandas/commit/1002cc339d81591b280ec3ec3c8ac58ce157e3b6?src=pr&el=desc) will **not change** coverage.
> The diff coverage is `n/a`.

[![Impacted file tree graph](https://codecov.io/gh/pandas-dev/pandas/pull/16221/graphs/tree.svg?token=eZ4WkYLtcO&width=650&src=pr&height=150)](https://codecov.io/gh/pandas-dev/pandas/pull/16221?src=pr&el=tree)

```diff
@@           Coverage Diff           @@
##           master   #16221   +/-   ##
=======================================
  Coverage   90.86%   90.86%           
=======================================
  Files         162      162           
  Lines       50887    50887           
=======================================
  Hits        46240    46240           
  Misses       4647     4647
```

| Flag | Coverage Δ | |
|---|---|---|
| #multiple | `88.65% <ø> (ø)` | :arrow_up: |
| #single | `40.31% <ø> (ø)` | :arrow_up: |


------

[Continue to review full report at Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/16221?src=pr&el=continue).
> **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
> `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
> Powered by [Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/16221?src=pr&el=footer). Last update [1002cc3...2775d9b](https://codecov.io/gh/pandas-dev/pandas/pull/16221?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).

# [Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/16221?src=pr&el=h1) Report
> Merging [#16221](https://codecov.io/gh/pandas-dev/pandas/pull/16221?src=pr&el=desc) into [master](https://codecov.io/gh/pandas-dev/pandas/commit/1002cc339d81591b280ec3ec3c8ac58ce157e3b6?src=pr&el=desc) will **decrease** coverage by `0.62%`.
> The diff coverage is `n/a`.

[![Impacted file tree graph](https://codecov.io/gh/pandas-dev/pandas/pull/16221/graphs/tree.svg?src=pr&width=650&token=eZ4WkYLtcO&height=150)](https://codecov.io/gh/pandas-dev/pandas/pull/16221?src=pr&el=tree)

```diff
@@            Coverage Diff             @@
##           master   #16221      +/-   ##
==========================================
- Coverage   90.86%   90.23%   -0.63%     
==========================================
  Files         162      164       +2     
  Lines       50887    50894       +7     
==========================================
- Hits        46240    45926     -314     
- Misses       4647     4968     +321
```

| Flag | Coverage Δ | |
|---|---|---|
| #multiple | `88.02% <ø> (-0.63%)` | :arrow_down: |
| #single | `40.3% <ø> (-0.01%)` | :arrow_down: |

| [Impacted Files](https://codecov.io/gh/pandas-dev/pandas/pull/16221?src=pr&el=tree) | Coverage Δ | |
|---|---|---|
| [pandas/core/indexes/category.py](https://codecov.io/gh/pandas-dev/pandas/pull/16221?src=pr&el=tree#diff-cGFuZGFzL2NvcmUvaW5kZXhlcy9jYXRlZ29yeS5weQ==) | `98.48% <ø> (ø)` | :arrow_up: |
| [pandas/core/indexes/interval.py](https://codecov.io/gh/pandas-dev/pandas/pull/16221?src=pr&el=tree#diff-cGFuZGFzL2NvcmUvaW5kZXhlcy9pbnRlcnZhbC5weQ==) | `92.58% <ø> (ø)` | :arrow_up: |
| [pandas/io/formats/excel.py](https://codecov.io/gh/pandas-dev/pandas/pull/16221?src=pr&el=tree#diff-cGFuZGFzL2lvL2Zvcm1hdHMvZXhjZWwucHk=) | `73.15% <0%> (-23.49%)` | :arrow_down: |
| [pandas/io/excel.py](https://codecov.io/gh/pandas-dev/pandas/pull/16221?src=pr&el=tree#diff-cGFuZGFzL2lvL2V4Y2VsLnB5) | `61.68% <0%> (-18.94%)` | :arrow_down: |
| [pandas/core/tools/datetimes.py](https://codecov.io/gh/pandas-dev/pandas/pull/16221?src=pr&el=tree#diff-cGFuZGFzL2NvcmUvdG9vbHMvZGF0ZXRpbWVzLnB5) | `66.94% <0%> (-18.62%)` | :arrow_down: |
| [pandas/core/config.py](https://codecov.io/gh/pandas-dev/pandas/pull/16221?src=pr&el=tree#diff-cGFuZGFzL2NvcmUvY29uZmlnLnB5) | `69.72% <0%> (-18.37%)` | :arrow_down: |
| [pandas/core/indexes/base.py](https://codecov.io/gh/pandas-dev/pandas/pull/16221?src=pr&el=tree#diff-cGFuZGFzL2NvcmUvaW5kZXhlcy9iYXNlLnB5) | `95.75% <0%> (-0.46%)` | :arrow_down: |
| [pandas/compat/\_\_init\_\_.py](https://codecov.io/gh/pandas-dev/pandas/pull/16221?src=pr&el=tree#diff-cGFuZGFzL2NvbXBhdC9fX2luaXRfXy5weQ==) | `61.77% <0%> (-0.45%)` | :arrow_down: |
| [pandas/io/parsers.py](https://codecov.io/gh/pandas-dev/pandas/pull/16221?src=pr&el=tree#diff-cGFuZGFzL2lvL3BhcnNlcnMucHk=) | `95.32% <0%> (-0.33%)` | :arrow_down: |
| [pandas/util/testing.py](https://codecov.io/gh/pandas-dev/pandas/pull/16221?src=pr&el=tree#diff-cGFuZGFzL3V0aWwvdGVzdGluZy5weQ==) | `78.87% <0%> (-0.2%)` | :arrow_down: |
| ... and [33 more](https://codecov.io/gh/pandas-dev/pandas/pull/16221?src=pr&el=tree-more) | |

------

[Continue to review full report at Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/16221?src=pr&el=continue).
> **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
> `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
> Powered by [Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/16221?src=pr&el=footer). Last update [1002cc3...4dc57b4](https://codecov.io/gh/pandas-dev/pandas/pull/16221?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).

Another sphinx / rst mystery ... 
So for some reason this works for Categorical, but not for IntervalIndex. No idea why. 
And the strange thing is that I originally said in the PR that introduced this that "it was not yet working" :-) (https://github.com/pandas-dev/pandas/pull/9721). But apparently is does, at least for Categorical.
Strange... I thought I had tried it too, but I can't remember the outcome. Did you clear all the generated files before rebuilding?
@jorisvandenbossche I wonder if it's https://github.com/pandas-dev/pandas/commit/cf40991093e746e5dde40fca4f322ecfc3dfff78#diff-4501fdb73fd4b9f09d44a3f4177d44aaR46

We special case `.Categorical` there.
Here's what it looks like
![screen shot 2017-05-04 at 3 06 10 pm](https://cloud.githubusercontent.com/assets/1312546/25722945/9ad332ce-30db-11e7-811a-d9d21f72064a.png)

No new warnings with that.

I spent a bit longer trying to get a an autosummary with a subset of the Methods specified in a `Methods` section, but no luck. Will probably require some modifications to numpydoc (beyond just templates), which will have to wait till after the release.
Aha, you have found out how I hacked it before .. :-) Thanks!
Doc build log [looks good](https://travis-ci.org/pandas-dev/pandas/jobs/228882935), merging: 
Great!
yep looks great. thanks guys!