How to position the legend such that it is not over the plots and also how to make horizontal legends?

5 visualizaciones (últimos 30 días)
I am plotting mxn matrix (y-axis) with the mx1 vector (x-axis). However, the plot just looks bad for cases of more than 10 legends. Is there a way that I can align the legends above the plots, and also if I can create horizontal legends occupying the available horizontal space according to the plot? The plot will have unknown n variables, so it becomes difficult to align the legends each time I create a new plot.

Respuesta aceptada

Adam Danz
Adam Danz el 16 de Nov. de 2020
Editada: Adam Danz el 17 de Nov. de 2020
See the location, orientation, and NumColumns options

Más respuestas (0)

Categorías

Más información sobre Legend en Help Center y File Exchange.

Etiquetas

Productos


Versión

R2020b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by