LegendOrientation
is an option for Legend that specifies the direction in which key boxes are laid out.
LegendOrientation
LegendOrientation
is an option for Legend that specifies the direction in which key boxes are laid out.
Details and Options
- To use LegendOrientation, you first need to load the Plot Legends Package using Needs["PlotLegends`"].
- The following settings can be given:
-
Horizontal left to right Vertical top to bottom
Examples
Basic Examples (1)
Needs["PlotLegends`"]Legend keys are next to each other:
Plot[{Sin[x], Cos[x]}, {x, 0, 2Pi}, PlotLegend -> {"sine", "cosine"}, LegendOrientation -> Horizontal]Legend keys are above one another:
Plot[{Sin[x], Cos[x]}, {x, 0, 2Pi}, PlotLegend -> {"sine", "cosine"}, LegendOrientation -> Vertical]See Also
Tech Notes
Related Guides
Text
Wolfram Research (2007), LegendOrientation, Wolfram Language function, https://reference.wolfram.com/language/PlotLegends/ref/LegendOrientation.html.
CMS
Wolfram Language. 2007. "LegendOrientation." Wolfram Language & System Documentation Center. Wolfram Research. https://reference.wolfram.com/language/PlotLegends/ref/LegendOrientation.html.
APA
Wolfram Language. (2007). LegendOrientation. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/PlotLegends/ref/LegendOrientation.html
BibTeX
@misc{reference.wolfram_2026_legendorientation, author="Wolfram Research", title="{LegendOrientation}", year="2007", howpublished="\url{https://reference.wolfram.com/language/PlotLegends/ref/LegendOrientation.html}", note=[Accessed: 15-June-2026]}
BibLaTeX
@online{reference.wolfram_2026_legendorientation, organization={Wolfram Research}, title={LegendOrientation}, year={2007}, url={https://reference.wolfram.com/language/PlotLegends/ref/LegendOrientation.html}, note=[Accessed: 15-June-2026]}