# Font Size in Plot Legends

How can I change the font size of the Legend? I have to plot 5 functions, and I already wrote the code, with the colors and so on.

But when I write the final code for the PlotLegends, that is

PlotLegends ->
Placed[{Style["\[Nu] = 0", Black, 10], ["\[Nu]=0.25", Red,
10],["\[Nu]=0.5", Green, 10] AND SO ON }, {0.2, 0.7}]


It doesn't work.

I want to change the plot legend size, in order to have a better plot.

• You didn't give code other people can run, so try this: Plot[Table[ChebyshevT[k, x], {k, 1, 3}] // Evaluate, {x, -1, 1}, PlotLegends -> Placed[LineLegend[MapThread[Style, {{"k = 1", "k = 2", "k = 3"}, {Black, Red, Green}}], LabelStyle -> 10], {0.25, 0.65}]] – J. M. is away Sep 26 '18 at 14:07
• @J.M.issomewhatokay. That works perfectly! Just one more question: how to change the font? Say I want to use Times New Roman, or Serif... – Henry Sep 26 '18 at 15:04
• Just modify the LabelStyle setting: LabelStyle -> {10, FontFamily -> "Times New Roman"}. Please read the docs for LineLegend[], it's all there. – J. M. is away Sep 26 '18 at 15:29

LineLegend is the function that ultimately constructs the legend for Plot. It has a lot of options that can be modified to adjust the appearance of the legend. If you're trying to control the size, the most useful options are probably

• LabelStyle: change the overall style for the labels, including font size
• LegendMarkerSize: control how long the sample lines are
• LegendMargins: control how much space is left around the legend
• LegendLayout: switch from column to row

Here are some examples of each of these options being used:

{Framed[LineLegend[{Red, Green, Blue}, {"red", "green", "blue"}]],
Framed[LineLegend[{Red, Green, Blue}, {"red", "green", "blue"},
LabelStyle -> 10]],
Framed[LineLegend[{Red, Green, Blue}, {"red", "green", "blue"},
LegendMarkerSize -> 5]],
Framed[LineLegend[{Red, Green, Blue}, {"red", "green", "blue"},
LegendMargins -> 0]],
Framed[LineLegend[{Red, Green, Blue}, {"red", "green", "blue"},
LegendLayout -> "Row"]]}


Individually they may not be much smaller, but using them together can have a much bigger effect.

Framed[LineLegend[{Red, Green, Blue}, {"red", "green", "blue"},
LabelStyle -> 10, LegendMarkerSize -> 5, LegendMargins -> 0]]