Published
Edited
Feb 23, 2022
Fork of Simple D3
Insert cell
Insert cell
Insert cell
Insert cell
nodes_data = d3.hierarchy(data_1, d => d.children);
Insert cell
nodes = tree(nodes_data)
Insert cell
width = 1000
Insert cell
Insert cell
Insert cell
margin ={return {left:20, top:20,right:60, bottom:20 }}
Insert cell
diagonal = d3.linkHorizontal().x(d => d.y).y(d => d.x)
Insert cell
dx=10
Insert cell
dy = width/2
Insert cell
### Appendix
Insert cell
Insert cell
data_2 = {
return { "name":"Firewall b2",
"children": [
{
"name": "Pod 1"
},
{
"name": "Hypervisor 2a"
},
{
"name": " Pod 3",
"children": [
{
"name": "Hypervisor 3b",
"children": [],
},
{
"name": "Hypervisor 3b",
"children": [
{
"name": "VNF 3b",
},
{
"name": "VNF 4D",
},
{
"name": "VNF 5F",
}
],
}
]
},
{
"name": "Azura"
}
]
}
}
Insert cell

Purpose-built for displays of data

Observable is your go-to platform for exploring data and creating expressive data visualizations. Use reactive JavaScript notebooks for prototyping and a collaborative canvas for visual data exploration and dashboard creation.
Learn more