Message Boards Message Boards

[✓] Increase the size of a legend in LisDensityPlot?

GROUPS:

How can I increase legend size in ListDensityPlot? I tried that by using LegendSize, but it doesn't work in Mathematica 10. Thanks.

POSTED BY: Ghady Almufleh
Answer
2 months ago

Without some example code, what you actually tried it is hard to answer where it went wrong. On my machine on Mathematica 9, the following works:

ListDensityPlot[
 Table[Sin[j^2 + i], {i, 0, Pi, 0.02}, {j, 0, Pi, 0.02}],
 PlotLegends -> 
  Placed[BarLegend[Automatic, LegendMarkerSize -> 500], Right]
]

Mathematica graphics

POSTED BY: Patrick Scheibe
Answer
2 months ago

Thank you for your help. I meant increasing the size of font of legend. By the way, I solved by using this:

PlotLegends -> BarLegend[Automatic, LabelStyle -> {FontSize -> 15}]
POSTED BY: Ghady Almufleh
Answer
2 months ago

Exactly. I wasn't really sure what you exactly wanted to enlarge but it was my hope that you see that you can adjust different things of legend by packing it in the PlotLegends option.

POSTED BY: Patrick Scheibe
Answer
2 months ago

@Ghady Almufleh, Welcome to Wolfram Community! Please make sure you know the rules: https://wolfr.am/READ-1ST

You should always post your sample code.

POSTED BY: Moderation Team
Answer
2 months ago

Group Abstract Group Abstract