Skip to content
Merged
Changes from all commits
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
8 changes: 4 additions & 4 deletions pandas/core/strings/accessor.py
Original file line number Diff line number Diff line change
Expand Up @@ -2350,7 +2350,7 @@ def extractall(self, pat, flags=0):
0
match
A 0 1
1 2
1 2
B 0 1

Capture group names are used for column names of the result.
Expand All @@ -2359,7 +2359,7 @@ def extractall(self, pat, flags=0):
digit
match
A 0 1
1 2
1 2
B 0 1

A pattern with two groups will return a DataFrame with two columns.
Expand All @@ -2368,7 +2368,7 @@ def extractall(self, pat, flags=0):
letter digit
match
A 0 a 1
1 a 2
1 a 2
B 0 b 1

Optional groups that do not match are NaN in the result.
Expand All @@ -2377,7 +2377,7 @@ def extractall(self, pat, flags=0):
letter digit
match
A 0 a 1
1 a 2
1 a 2
B 0 b 1
C 0 NaN 1
"""
Expand Down