Literal nan string stored in dataframe using json_normalize for null value in string metadata column · Issue #25468 · pandas-dev/pandas (original) (raw)

Skip to content

Provide feedback

Saved searches

Use saved searches to filter your results more quickly

Sign up

@joetl

Description

@joetl

Code Sample, a copy-pastable example if possible

Your code here

import pandas as pd data = [{"name": "test","address": [{"add": "add1"}]},{"address": [{"add": "add2"}]}] df = pd.io.json.json_normalize(data,"address","name",errors="ignore") df

Problem description

In Json_normalize if the metadata column is nullable with option errors set as ignore the null values in dataframe are literal nan string and not numpy.nan

Expected Output

Expecting to see numpy.nan for null metadata string column values instead of nan string

Pandas version 0.24.1