Giving different colors in skyplot when default colors repeat
Mostrar comentarios más antiguos
Hi all,
I was trying to get a skyplot for 15 different satellites but it seems that the colors in the legend is repeating. I actually wanted to give unique colors for the individual satellites, and tried the following:
initialColorOrder = get(gca,'ColorOrder') % to display the initial colors
newDefaultColors = copper(15)
set(gca, 'ColorOrder', newDefaultColors, 'NextPlot', 'replacechildren')
newColorOrder = get(gca,'ColorOrder') % to display the new colors
skyplot(azimuth, elevation, GroupData=categorical(g))
legend()
Even though I could see that newColorOrder now contains 15 different colors its not reflected in the skyplot which still is using the initial default colors. Any suggestion why that is happening?
I also tried the following:
skyplot(azimuth, elevation, GroupData=categorical(g))
legend()
colororder(parula(15))
Even though it appears to give what I desired, the individual colors are most of the times indistinguishable ''visually''.
Thanks
Respuesta aceptada
Más respuestas (1)
Categorías
Más información sobre Reference Applications en Centro de ayuda y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!




