VertexStyle

VertexStyle

is an option and annotation for Graph and related functions that specifies what style to use for vertices.

Details

  • The following option settings can be used:
  • Automaticuse automatic setting for style
    styleuse style for all vertices
    {v1style1,v2style2,}use stylei for vertex vi
    {patt1style1,patt2style2,}use stylei for vertices matching the pattern patti
  • Vertices with no explicit vertex style v->style are taken to use the automatic style.
  • The wrapper Style[v,style] is equivalent to Annotation[v,VertexStyle->style] and can be used when creating graphs in functions such as Graph etc.
  • VertexStyle can apply to points, lines, and faces.
  • To specify multiple style directives use Directive[style1,style2,].
  • Style and other specifications are effectively applied in the order VertexStyle, Style and other wrappers, and VertexShapeFunction, with later specifications overriding earlier ones.

Examples

open allclose all

Basic Examples  (2)

Set the style for all vertices:

Specify the style for individual vertices:

Scope  (10)

VertexStyle can be used for general graphs:

Matrix graphs:

Special graphs:

Random graphs:

Use VertexStyle in an Annotation wrapper:

Alternatively, use a Style wrapper:

Use Directive to set multiple style directives:

VertexStyle works with patterns:

VertexStyle can be combined with VertexShapeFunction:

VertexShapeFunction has higher priority than VertexStyle:

VertexStyle can be combined with BaseStyle:

VertexStyle has higher priority than BaseStyle:

VertexShape is not affected by VertexStyle:

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

Text

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

CMS

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

APA

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

BibTeX

@misc{reference.wolfram_2023_vertexstyle, author="Wolfram Research", title="{VertexStyle}", year="2010", howpublished="\url{https://reference.wolfram.com/language/ref/VertexStyle.html}", note=[Accessed: 18-April-2024 ]}

BibLaTeX

@online{reference.wolfram_2023_vertexstyle, organization={Wolfram Research}, title={VertexStyle}, year={2010}, url={https://reference.wolfram.com/language/ref/VertexStyle.html}, note=[Accessed: 18-April-2024 ]}