Plotting three histograms as a curved line on the same graph
Afficher commentaires plus anciens
I have three large 200,000*1 vectors (z1,z2 and z3) with contains data and I am looking to plot all three as a histogram (but I would like a curved line which can be jagged) on the same graph. I have looked through the website and I altered a code that was used in another answer:
>> x=-10:0.01:10;
[n1, xout1] = hist(z1,x);
bar(xout1,n1,'r'); grid; hold
[n2, xout2] = hist(z2,x);
bar(xout2,n2,'g'); grid; hold
[n3, xout3] = hist(z3,x);
bar(xout3,n3,'g')
The problem was that the graph histograms are solid colours so I cannot see past the histogram that overlaps the other two histograms. I don't mind having slightly jagged edges on my curve, I don't expect it to be perfectly 'smooth'. Does anyone know how I can make my graphs 'transparent'?
Réponse acceptée
Plus de réponses (0)
Catégories
En savoir plus sur Histograms dans Centre d'aide et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!