1
$\begingroup$

I have a problem with the font's of my plots. Whenever I try to plot something the fonts of the plot and the legend are different. I was unable to find whether there is a possibility to change the font of the plotlegend, is this possible?

Cheers

Show[
 Plot[
  betap[eta], {eta, 0, 0.65},
  PlotStyle -> {Red},
  AxesOrigin -> {0, 0}, FrameLabel -> {"x", "y", "Title."},
  Frame -> True,
  PlotLegends -> {"Model"},
  PlotRange -> {{0, 0.7}, Automatic}
  ],
 ErrorListPlot[lst2, PlotStyle -> {Black, {PointSize[0.004]}}, 
  PlotLegends -> {"Data"}]
 ]

enter image description here

$\endgroup$
2
$\begingroup$

You just need to set the same LabelStyle for both plots,

With[{style = {FontFamily -> #,
    FontSize -> 18, FontColor -> Black}},
 Show[
    Plot[E^eta, {eta, 0, 0.65}, PlotStyle -> {Red},
     FrameLabel -> {"x", "y", "Title."},
     Frame -> True,
     ImageSize -> 400,
     PlotLegends -> {"Model"},
     LabelStyle -> style
     ],
    ListPlot[{{0, 1}, {.2, 1.2}, {.4, 1.4}},
     PlotLegends -> {"Data"},
     LabelStyle -> style]
    ]] & /@ {"Helvetica", "Times New Roman"}

enter image description here

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.