From 4432033b61865cd5216feac2399b927ba85c9d8d Mon Sep 17 00:00:00 2001 From: Nick Crews Date: Sun, 30 Jun 2024 15:17:55 -0800 Subject: [PATCH] Add "N / A" to `STR_NA_VALUES` This is a value that I just came across in some data that is in the spirit of the other NA value. I don't think this will be a false positive any more so than some of the other values in this list. --- pandas/_libs/parsers.pyx | 1 + pandas/tests/io/parser/test_na_values.py | 1 + 2 files changed, 2 insertions(+) diff --git a/pandas/_libs/parsers.pyx b/pandas/_libs/parsers.pyx index c29cdbcf5975e..b6d29672c8d30 100644 --- a/pandas/_libs/parsers.pyx +++ b/pandas/_libs/parsers.pyx @@ -1378,6 +1378,7 @@ STR_NA_VALUES = { "#N/A N/A", "#N/A", "N/A", + "N / A", "n/a", "NA", "", diff --git a/pandas/tests/io/parser/test_na_values.py b/pandas/tests/io/parser/test_na_values.py index 1e370f649aef8..9c54917487a66 100644 --- a/pandas/tests/io/parser/test_na_values.py +++ b/pandas/tests/io/parser/test_na_values.py @@ -119,6 +119,7 @@ def test_default_na_values(all_parsers): "-1.#QNAN", "#N/A", "N/A", + "N / A", "n/a", "NA", "",