Skip to content

Commit 97ad1cf

Browse files
committed
DOC: document ignore_index in concat in docstring and sphinx docs, GH #619
1 parent f494fbd commit 97ad1cf

File tree

2 files changed

+9
-0
lines changed

2 files changed

+9
-0
lines changed

doc/source/merging.rst

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -72,6 +72,10 @@ some configurable handling of "what to do with the other axes":
7272
- ``verify_integrity``: boolean, default False. Check whether the new
7373
concatenated axis contains duplicates. This can be very expensive relative
7474
to the actual data concatenation
75+
- ``ignore_index`` : boolean, default False. If True, do not use the index
76+
values on the concatenation axis. The resulting axis will be labeled 0, ...,
77+
n - 1. This is useful if you are concatenating objects where the
78+
concatenation axis does not have meaningful indexing information.
7579

7680
Without a little bit of context and example many of these arguments don't make
7781
much sense. Let's take the above example. Suppose we wanted to associate

pandas/tools/merge.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -622,6 +622,11 @@ def concat(objs, axis=0, join='outer', join_axes=None, ignore_index=False,
622622
MultiIndex. Otherwise they will be inferred from the keys
623623
names : list, default None
624624
Names for the levels in the resulting hierarchical index
625+
ignore_index : boolean, default False
626+
If True, do not use the index values on the concatenation axis. The
627+
resulting axis will be labeled 0, ..., n - 1. This is useful if you are
628+
concatenating objects where the concatenation axis does not have
629+
meaningful indexing information.
625630
626631
Notes
627632
-----

0 commit comments

Comments
 (0)