我有以下JSON数据:
{
"categories": [
{
"category_id": "11decadd",
"name": "Com",
"category_type": "Type",
"position": 5,
"vela_defined": True,
"created_at": "2017-02-15 01:49:23 -0700",
"updated_at": "2017-02-15 01:49:23 -0700"
},
{
"category_id": "c7010763",
"name": "none",
"category_type": "EquipmentStatus",
"position": 1,
"vela_defined": True,
"created_at": "2017-02-15 01:49:23 -0700",
"updated_at": "2018-03-01 04:20:38 -0700"
}
],
"customizable_categories": [
{
"customizable_category_id": "435ae18b",
"name": "NA",
"category_id": "11decadd",
"position": 1,
"created_at": "2017-02-15 01:49:23 -0700",
"updated_at": "2017-02-15 01:49:23 -0700"
},
{
"customizable_category_id": "51e607d8",
"name": "Third Party",
"category_id": "fafab667",
"position": 2,
"created_at": "2017-02-15 01:49:23 -0700",
"updated_at": "2017-02-15 01:49:23 -0700"
}
],
"equipment_category_status_sets": [
]
}
我尝试将其转换为3x Pandas数据帧(由JSON顶级条目命名)
但似乎无法让它加载。有什么建议吗?
答案 0 :(得分:2)
我认为DataFrame
的{{1}}构造函数需要字典理解:
dictionary of DataFrame