TreeElementSize

TreeElementSize

is an option for Tree and related functions that specifies what size should be used for subtree elements.

Details

  • TreeElementSize allows specifying the size of the root node of a tree, as well as that of any subtrees at positions matching a pattern.
  • The following settings can be used:
  • Automaticautomatically compute size
    Tiny,Small,Medium,Largeuse tiny, small, etc. sizes
    {"Nearest",s}fraction of minimum distance between subtree element coordinates
    {"Scaled",s}fraction of overall diagonal for all subtree element coordinates
    {sx,sy}specify size in the x and y directions
    Allsuse s at all nodes
    TreeCases[pattern]suse s at nodes with data matching pattern
    {pos1s1,pos2s2,}use si at position posi
    {patt1s1,patt2s2,}use si at positions matching the pattern patti
  • TreeElementSizes for a number s is taken to be TreeElementSize{"Nearest",s}.
  • A size {sx,sy} indicates a rectangle region with center {x,y}, lower-left corner {x-sx,y-sy} and upper-right corner {x+sx,y+sy}.
  • TreeElementSizeFunction specifications override TreeElementSize specifications.

Examples

open allclose all

Basic Examples  (3)

Specify an individual node size:

Specify a list of node sizes:

Use the same size for all nodes:

Scope  (5)

Size Specification  (4)

Use symbolic subtree element sizes:

Use a fraction of the minimum distance between subtree element coordinates:

Use a fraction of the overall diagonal for all subtree element coordinates:

Specify size in both the and directions:

Position Specification  (1)

Specify positions using position patterns:

Specify positions using data patterns:

Properties & Relations  (4)

Sizes for subtree elements can be specified by position:

Sizes specified by a subtree take precedence over sizes specified by its ancestors:

A position {i,j,} in a subtree refers to its subtree at relative position {i,j,}:

A relative position {2} at position {1} refers to the global position {1,2}:

In general, a pattern patt applies to subtrees at global positions {i,j,} that match patt:

A list of patterns {patt1,patt2,} applies to relative positions {i,j,} that match patti:

Wolfram Research (2022), TreeElementSize, Wolfram Language function, https://reference.wolfram.com/language/ref/TreeElementSize.html.

Text

Wolfram Research (2022), TreeElementSize, Wolfram Language function, https://reference.wolfram.com/language/ref/TreeElementSize.html.

CMS

Wolfram Language. 2022. "TreeElementSize." Wolfram Language & System Documentation Center. Wolfram Research. https://reference.wolfram.com/language/ref/TreeElementSize.html.

APA

Wolfram Language. (2022). TreeElementSize. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/TreeElementSize.html

BibTeX

@misc{reference.wolfram_2024_treeelementsize, author="Wolfram Research", title="{TreeElementSize}", year="2022", howpublished="\url{https://reference.wolfram.com/language/ref/TreeElementSize.html}", note=[Accessed: 22-December-2024 ]}

BibLaTeX

@online{reference.wolfram_2024_treeelementsize, organization={Wolfram Research}, title={TreeElementSize}, year={2022}, url={https://reference.wolfram.com/language/ref/TreeElementSize.html}, note=[Accessed: 22-December-2024 ]}