Clarify equals method docstring
State: closed

Make explicit that equals method requires that columns have the same dtypes but not that indices have the same types (e.g. `pd.DataFrame({1:[0], 0:[1]}).equals(pd.DataFrame({1.0:[0], 0.0:[1]}))` returns `True` while `pd.DataFrame({1:[0], 0:[1]}, dtype='float32').equals(pd.DataFrame({1:[0], 0:[1]}, dtype='float64'))` returns `False`)

- [ ] closes #xxxx
- [ ] tests added / passed
- [ ] passes `git diff upstream/master -u -- "*.py" | flake8 --diff`
- [ ] whatsnew entry


Labels:
name: Docs

Comments:
# [Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/19213?src=pr&el=h1) Report
> Merging [#19213](https://codecov.io/gh/pandas-dev/pandas/pull/19213?src=pr&el=desc) into [master](https://codecov.io/gh/pandas-dev/pandas/commit/8347ff8c9d8876fa46f73dbc48919a672caef1d2?src=pr&el=desc) will **increase** coverage by `0.02%`.
> The diff coverage is `n/a`.

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

```diff
@@            Coverage Diff             @@
##           master   #19213      +/-   ##
==========================================
+ Coverage   91.53%   91.55%   +0.02%     
==========================================
  Files         147      147              
  Lines       48797    48797              
==========================================
+ Hits        44664    44675      +11     
+ Misses       4133     4122      -11
```

| Flag | Coverage Δ | |
|---|---|---|
| #multiple | `89.92% <ø> (+0.02%)` | :arrow_up: |
| #single | `41.6% <ø> (ø)` | :arrow_up: |

| [Impacted Files](https://codecov.io/gh/pandas-dev/pandas/pull/19213?src=pr&el=tree) | Coverage Δ | |
|---|---|---|
| [pandas/core/generic.py](https://codecov.io/gh/pandas-dev/pandas/pull/19213/diff?src=pr&el=tree#diff-cGFuZGFzL2NvcmUvZ2VuZXJpYy5weQ==) | `95.9% <ø> (ø)` | :arrow_up: |
| [pandas/core/dtypes/cast.py](https://codecov.io/gh/pandas-dev/pandas/pull/19213/diff?src=pr&el=tree#diff-cGFuZGFzL2NvcmUvZHR5cGVzL2Nhc3QucHk=) | `88.35% <0%> (-0.31%)` | :arrow_down: |
| [pandas/core/internals.py](https://codecov.io/gh/pandas-dev/pandas/pull/19213/diff?src=pr&el=tree#diff-cGFuZGFzL2NvcmUvaW50ZXJuYWxzLnB5) | `94.5% <0%> (ø)` | :arrow_up: |
| [pandas/core/dtypes/common.py](https://codecov.io/gh/pandas-dev/pandas/pull/19213/diff?src=pr&el=tree#diff-cGFuZGFzL2NvcmUvZHR5cGVzL2NvbW1vbi5weQ==) | `94.58% <0%> (+0.04%)` | :arrow_up: |
| [pandas/plotting/\_converter.py](https://codecov.io/gh/pandas-dev/pandas/pull/19213/diff?src=pr&el=tree#diff-cGFuZGFzL3Bsb3R0aW5nL19jb252ZXJ0ZXIucHk=) | `66.95% <0%> (+1.73%)` | :arrow_up: |

------

[Continue to review full report at Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/19213?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/19213?src=pr&el=footer). Last update [8347ff8...3bc9bfd](https://codecov.io/gh/pandas-dev/pandas/pull/19213?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).

Sorry, I meant "column labels" rather than "indices."
We check the indices for equality. But we happen to have this case.

```
In [7]: a
Out[7]: Int64Index([1, 0], dtype='int64')

In [8]: b
Out[8]: Float64Index([1.0, 0.0], dtype='float64')

In [9]: a.equals(b)
Out[9]: True
```
We normally DO consider that case equal, but I think we discussed in some other issues that from a user point of view these are not equal.

cc @toobaz @TomAugspurger @jorisvandenbossche 
Without having thought much about this, I would have said that the indexes case (can be discussed, but mostly) is fine, while ``pd.DataFrame({1:[0], 0:[1]}, dtype='float32').equals(pd.DataFrame({1:[0], 0:[1]}, dtype='float64'))`` should have returned ``True``...

but assuming I'm wrong (i.e. current behavior is OK), then I just suggest replacing ``the same dtypes at corresponding locations`` with ``the same dtype(s)`` in the patch.
Closing this PR as discontinued. It's not in a state to be merged, and the user deleted the fork/branch it's based on.

Opened #22462 as I think it's better to start from the beginning on this docstring.