Skip to content

TreeGraph ​

Wolfram's own TreeGraph, held inert -- the expression is what a worksheet or REPL draws, not something this library computes (see @enumeratio/formats/src/graphics.ts).

Wolfram LanguageTreeGraph
TreeGraph(...)Wolfram's own TreeGraph, held inert -- the expression is what a worksheet or REPL draws, not something this library computes (see @enumeratio/formats/src/graphics.ts).
Typed signatures
TypePackageApplies
(any*) -> anyformatsalways

Domain: Graphics·Drawn as Graphics

Examples

Basic #

A rooted tree, laid out by depth

live ↗
InTreeGraph({label→’root’,  children→[List,{label→’a’},{label→’b’}]})\mathrm{TreeGraph}(\left\lbrace \text{label}→ \text{'root'},\;\text{children}→\bigl\lbrack\text{List}, \left\lbrace \text{label}→ \text{'a'}\right\rbrace, \left\lbrace \text{label}→ \text{'b'}\right\rbrace\bigr\rbrack\right\rbrace)OutTreeGraph({label→root,  children→[{label→’a’},{label→’b’}]})\mathrm{TreeGraph}(\left\lbrace \text{label}→ \text{root},\;\text{children}→\bigl\lbrack\left\lbrace \text{label}→ \text{'a'}\right\rbrace, \left\lbrace \text{label}→ \text{'b'}\right\rbrace\bigr\rbrack\right\rbrace)
About
Examples1
CrosswalkWolfram Language