Public
Edited
Dec 14, 2023
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
counter
Insert cell
Insert cell
Insert cell
Insert cell
test = FileAttachment("test.svg").image()
Insert cell
Insert cell
treePaths
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
pathForInstance = extractPathFromTable(instanceId, treePaths);
Insert cell
allPathElementsFound = path(d3.hierarchy(currentTreeData), pathForInstance)
Insert cell
Insert cell
pathForInstance[pathForInstance.length - 1]
Insert cell
nodes = d3.hierarchy(currentTreeData).descendants();
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
combined_forest_data = FileAttachment("combined_forest_data.json").json()
Insert cell
viewof ST = Inputs.select(
combined_forest_data.forest.map((tree, index) => `Tree ${index}`), // This maps over the 'forest' array
{ label: 'Select a Decision Tree:' }
);

Insert cell
root = d3.hierarchy(ST)
Insert cell
Insert cell

One platform to build and deploy the best data apps

Experiment and prototype by building visualizations in live JavaScript notebooks. Collaborate with your team and decide which concepts to build out.
Use Observable Framework to build data apps locally. Use data loaders to build in any language or library, including Python, SQL, and R.
Seamlessly deploy to Observable. Test before you ship, use automatic deploy-on-commit, and ensure your projects are always up-to-date.
Learn more