Skip to content

Instantly share code, notes, and snippets.

@eiherrera eiherrera/tree.json
Created Nov 8, 2019

Embed
What would you like to do?
{
"id": 0,
"is_leaf": false,
"survival": false,
"not_survival": false,
"attribute": "Gender",
"is_categorical": true,
"value": [
"female"
],
"children": [
{
"id": 1,
"is_leaf": false,
"survival": false,
"not_survival": false,
"attribute": "Class",
"is_categorical": false,
"value": 1.5,
"children": [
{
"id": 2,
"is_leaf": false,
"survival": false,
"not_survival": false,
"attribute": "Age group",
"is_categorical": true,
"value": [
"20 - 29",
"0 - 9"
],
"children": [
{
"id": 3,
"is_leaf": true,
"survival": 44,
"not_survival": 376,
"attribute": false,
"is_categorical": false,
"value": false
},
{
"id": 4,
"is_leaf": true,
"survival": 56,
"not_survival": 188,
"attribute": false,
"is_categorical": false,
"value": false
}
]
},
{
"id": 5,
"is_leaf": false,
"survival": false,
"not_survival": false,
"attribute": "Age",
"is_categorical": false,
"value": 54.5,
"children": [
{
"id": 6,
"is_leaf": true,
"survival": 3,
"not_survival": 25,
"attribute": false,
"is_categorical": false,
"value": false
},
{
"id": 7,
"is_leaf": true,
"survival": 58,
"not_survival": 93,
"attribute": false,
"is_categorical": false,
"value": false
}
]
}
]
},
{
"id": 8,
"is_leaf": false,
"survival": false,
"not_survival": false,
"attribute": "Class",
"is_categorical": false,
"value": 2.5,
"children": [
{
"id": 9,
"is_leaf": false,
"survival": false,
"not_survival": false,
"attribute": "Fare",
"is_categorical": false,
"value": 23.35,
"children": [
{
"id": 10,
"is_leaf": true,
"survival": 3,
"not_survival": 30,
"attribute": false,
"is_categorical": false,
"value": false
},
{
"id": 11,
"is_leaf": true,
"survival": 103,
"not_survival": 80,
"attribute": false,
"is_categorical": false,
"value": false
}
]
},
{
"id": 12,
"is_leaf": false,
"survival": false,
"not_survival": false,
"attribute": "Fare",
"is_categorical": false,
"value": 26.125,
"children": [
{
"id": 13,
"is_leaf": true,
"survival": 166,
"not_survival": 5,
"attribute": false,
"is_categorical": false,
"value": false
},
{
"id": 14,
"is_leaf": true,
"survival": 67,
"not_survival": 12,
"attribute": false,
"is_categorical": false,
"value": false
}
]
}
]
}
]
}
{
"id": 0,
"is_leaf": false,
"survival": false,
"not_survival": false,
"attribute": "Gender",
"is_categorical": true,
"value": [
"female"
],
"children": [
{
"id": 1,
"is_leaf": false,
"survival": false,
"not_survival": false,
"attribute": "Class",
"is_categorical": false,
"value": 1.5,
"children": [
{
"id": 2,
"is_leaf": false,
"survival": false,
"not_survival": false,
"attribute": "Age group",
"is_categorical": true,
"value": [
"20 - 29",
"0 - 9"
],
"children": [
{
"id": 3,
"is_leaf": true,
"survival": 44,
"not_survival": 376,
"attribute": false,
"is_categorical": false,
"value": false
},
{
"id": 4,
"is_leaf": true,
"survival": 56,
"not_survival": 188,
"attribute": false,
"is_categorical": false,
"value": false
}
]
},
{
"id": 5,
"is_leaf": false,
"survival": false,
"not_survival": false,
"attribute": "Age",
"is_categorical": false,
"value": 54.5,
"children": [
{
"id": 6,
"is_leaf": true,
"survival": 3,
"not_survival": 25,
"attribute": false,
"is_categorical": false,
"value": false
},
{
"id": 7,
"is_leaf": true,
"survival": 58,
"not_survival": 93,
"attribute": false,
"is_categorical": false,
"value": false
}
]
}
]
},
{
"id": 8,
"is_leaf": false,
"survival": false,
"not_survival": false,
"attribute": "Class",
"is_categorical": false,
"value": 2.5,
"children": [
{
"id": 9,
"is_leaf": false,
"survival": false,
"not_survival": false,
"attribute": "Fare",
"is_categorical": false,
"value": 23.35,
"children": [
{
"id": 10,
"is_leaf": true,
"survival": 3,
"not_survival": 30,
"attribute": false,
"is_categorical": false,
"value": false
},
{
"id": 11,
"is_leaf": true,
"survival": 103,
"not_survival": 80,
"attribute": false,
"is_categorical": false,
"value": false
}
]
},
{
"id": 12,
"is_leaf": false,
"survival": false,
"not_survival": false,
"attribute": "Fare",
"is_categorical": false,
"value": 26.125,
"children": [
{
"id": 13,
"is_leaf": true,
"survival": 166,
"not_survival": 5,
"attribute": false,
"is_categorical": false,
"value": false
},
{
"id": 14,
"is_leaf": true,
"survival": 67,
"not_survival": 12,
"attribute": false,
"is_categorical": false,
"value": false
}
]
}
]
}
]
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.