how can I draw histogram of a sine wave without "hist" command and with "plot" command?
2 visualizzazioni (ultimi 30 giorni)
Mostra commenti meno recenti
I want to write a program to draw a histogram for sine wave without the "hist" command and draw its histogram with "plot" command. the number of Bins can be a constant number. or evenif I can define a function that its input are : the number of Bins and the signal varible. I don't know how , can any body help me?
0 Commenti
Risposte (1)
Walter Roberson
il 9 Mar 2013
It can be done. You would need to use something like
plot( [1 1 2 2 3 3 4 4 5 5], [0 v1 v1 0 0 v2 v2 0 0 v3])
where v1, v2, v3 are the height values.
Have you considered using bar() instead of plot()
0 Commenti
Vedere anche
Categorie
Scopri di più su Histograms in Help Center e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!