Re: How change font size of Graph vertex labels?
- To: mathgroup at smc.vnet.net
- Subject: [mg117223] Re: How change font size of Graph vertex labels?
- From: Helen Read <readhpr at gmail.com>
- Date: Sat, 12 Mar 2011 05:07:24 -0500 (EST)
- References: <ilcqeh$im9$1@smc.vnet.net>
On 3/11/2011 4:36 AM, Murray Eisenberg wrote: > I want to make the "Names" labels of vertices in a Graph larger. The > "obvious" way... > > Graph[{1, 2, 3}, > {DirectedEdge[1, 2], DirectedEdge[2, 3], DirectedEdge[3, 1]}, > {VertexLabels -> {Placed["Name", Center]}, VertexSize -> {Medium}, > VertexStyle -> {24}}] > > ...seems to do nothing. And replacing the option VertexStyle -> {24} > with the wordier VertexStyle -> {FontSize->24} prevents Mathematica from > evaluating the Graph expression at all. > > (Mathematica 8.0.1) VertexStyle is for the vertices themselves. Use VertexLabelStyle to style the VertexLabels. Graph[{1, 2, 3}, {DirectedEdge[1, 2], DirectedEdge[2, 3], DirectedEdge[3, 1]}, {VertexLabels -> {Placed["Name", Center]}, VertexSize -> {Medium}, VertexStyle -> Red, VertexLabelStyle -> 24}] -- Helen Read University of Vermont