Skip to content

ENH: add NA scalar for missing value indicator, use in StringArray. #29597

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 25 commits into from
Dec 1, 2019
Merged
Changes from 1 commit
Commits
Show all changes
25 commits
Select commit Hold shift + click to select a range
03f83bd
ENH: add NA scalar for missing value indicator
jorisvandenbossche Nov 12, 2019
c1797d5
add np.nan to arithmetic/comparison tests
jorisvandenbossche Nov 13, 2019
3339eaa
use id(self) for hash
jorisvandenbossche Nov 13, 2019
e9d4d6a
fix api test
jorisvandenbossche Nov 13, 2019
4450d2d
move to cython
jorisvandenbossche Nov 13, 2019
1849a23
add examples to isna/notna docstring
jorisvandenbossche Nov 14, 2019
c72e3ee
Use NA scalar in string dtype (#1)
TomAugspurger Nov 14, 2019
3a97782
Merge remote-tracking branch 'upstream/master' into NA-scalar
jorisvandenbossche Nov 14, 2019
2302661
fix doctest
jorisvandenbossche Nov 14, 2019
2ab592a
small edits
jorisvandenbossche Nov 14, 2019
018399e
fix NA in repr
jorisvandenbossche Nov 15, 2019
31290b9
Merge remote-tracking branch 'upstream/master' into NA-scalar
TomAugspurger Nov 19, 2019
33fd3e0
remove redundant test
TomAugspurger Nov 19, 2019
289c885
remove dead code
TomAugspurger Nov 19, 2019
22de7cd
Merge remote-tracking branch 'upstream/master' into NA-scalar
jorisvandenbossche Nov 20, 2019
f8208db
fix divmod
jorisvandenbossche Nov 21, 2019
371eeeb
Merge remote-tracking branch 'upstream/master' into NA-scalar
jorisvandenbossche Nov 21, 2019
1cadeda
Merge remote-tracking branch 'upstream/master' into NA-scalar
jorisvandenbossche Nov 25, 2019
1fcf4b7
NA -> C_NA
jorisvandenbossche Nov 25, 2019
f6798e5
start some docs
jorisvandenbossche Nov 26, 2019
14c1434
futher doc updates
jorisvandenbossche Nov 27, 2019
788a2c2
Merge remote-tracking branch 'upstream/master' into NA-scalar
jorisvandenbossche Nov 27, 2019
1bcbab2
doc fixup
jorisvandenbossche Nov 27, 2019
775cdfb
Merge remote-tracking branch 'upstream/master' into NA-scalar
jorisvandenbossche Nov 27, 2019
589a961
further doc updates
jorisvandenbossche Nov 28, 2019
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
Prev Previous commit
Next Next commit
remove dead code
  • Loading branch information
TomAugspurger committed Nov 19, 2019
commit 289c8857b2646b2890fc079f37785adc4dd27463
7 changes: 0 additions & 7 deletions pandas/core/strings.py
Original file line number Diff line number Diff line change
Expand Up @@ -201,13 +201,6 @@ def _map_object(f, arr, na_mask=False, na_value=np.nan, dtype=object):
if na_mask:
mask = isna(arr)
convert = not np.all(mask)
if convert:
# XXX: This converts pd.NA to np.nan to match the output of
# object-dtype ops that return numeric, like str.count
# We probably want to return Int64Dtype instead.
# NA -> nan
arr[mask] = np.nan

try:
result = lib.map_infer_mask(arr, f, mask.view(np.uint8), convert)
except (TypeError, AttributeError) as e:
Expand Down