python pandas from json code example
Example 1: pandas to json
>>> df.to_json(orient='records')
'[{"col 1":"a","col 2":"b"},{"col 1":"c","col 2":"d"}]'
Example 2: read json pandas
df = pd.read_json('data.json')
>>> df.to_json(orient='records')
'[{"col 1":"a","col 2":"b"},{"col 1":"c","col 2":"d"}]'
df = pd.read_json('data.json')