Sources with the BigML Dashboard
3.3 JSON
BigML sources can also be created using JSON data in one of the following two formats:
3.3.1 List of Lists
A top-level list of lists of atomic values, each one defining a row. (See Figure 3.2 .)
3.3.2 List of Dictionaries
A top-level list of dictionaries, where each dictionary’s values represent the row values and the corresponding keys represent the column names as shown in Figure 3.3 . The first dictionary defines the keys that will be selected.
[
["Plan","Talk","Text","Purchases","Data","Age","Churn?"],
["family", 148, 72, 0, 33.6, 50, "TRUE"],
["business", 85, 66, 0, 26.6, 31, "FALSE"],
["business", 83, 64, 0, 23.3, 32, "TRUE"],
["individual", 9, 66, 94, 28.1, 21, "FALSE"],
["family", 15, 0, 0, 35.3, 29, "FALSE"],
["individual", 66, 72, 175, 25.8, 51,"TRUE"],
["business", 0, 0, 0, 30, 32, "TRUE"],
["family", 18, 84, 230, 45.8, 31, "TRUE"],
["individual", 71, 110, 240, 45.4, 54, "TRUE"],
["family", 59, 64, 0, 27.4, 40, "FALSE"]
]
[
{
"Plan": "family", "Talk": 148, "Text": 72, "Purchases": 0, "Data": 33.6,
"Age": 50, "Churn?": "TRUE"
},
{
"Plan": "business", "Talk": 85, "Text": 66, "Purchases": 0, "Data": 26.6,
"Age": 31, "Churn?": "FALSE"
},
{
"Plan": "business", "Talk": 83, "Text": 64, "Purchases": 0, "Data": 23.3,
"Age": 32, "Churn?": "TRUE"
},
{
"Plan": "individual", "Talk": 9, "Text": 66, "Purchases": 94, "Data": 28.1,
"Age": 21, "Churn?": "FALSE"
},
{
"Plan": "family", "Talk": 15, "Text": 0, "Purchases": 0, "Data": 35.3,
"Age": 29, "Churn?": "FALSE"
},
{
"Plan": "individual", "Talk": 66, "Text": 72, "Purchases": 175, "Data":
25.8,
"Age": 51, "Churn?": "TRUE"
},
{
"Plan": "business", "Talk": 0, "Text": 0, "Purchases": 0, "Data": 30,
"Age": 32, "Churn?": "TRUE"
},
{
"Plan": "family", "Talk": 18, "Text": 84, "Purchases": 230, "Data": 45.8,
"Age": 31, "Churn?": "TRUE"
},
{
"Plan": "individual", "Talk": 71, "Text": 110, "Purchases": 240, "Data":
45.4,
"Age": 54, "Churn?": "TRUE"
},
{
"Plan": "family", "Talk": 59, "Text": 64, "Purchases": 0, "Data": 27.4,
"Age": 40, "Churn?": "FALSE"
}
]