ksdensity with different colors
Mostrar comentarios más antiguos
I need to plot PDF using '' ksdensity(x) '' for many population at the same figure with different colors for each population.
Can anyone help please?
Regards Avan
Respuestas (1)
Walter Roberson
el 24 de Ag. de 2015
0 votos
plot the first, specifying a color. Use "hold on". Plot the second, specifying a different color. Plot the third, specifying a third color. Continue for the result of your populations. At the end, "hold off".
2 comentarios
Avan Al-Saffar
el 24 de Ag. de 2015
Editada: Avan Al-Saffar
el 24 de Ag. de 2015
Walter Roberson
el 24 de Ag. de 2015
Do not rely on ksdensity() to plot the values. Plot them yourself like is shown in the first example at http://www.mathworks.com/help/stats/ksdensity.html
Categorías
Más información sobre Exploration and Visualization 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!