I want to create a simple histogram of the data in a matrix, though when I use hist(matrix), the figure that is created consists of numerous rainbow-colored bars, which though they are in the shape of a histogram are not what I need...
94 ビュー (過去 30 日間)
古いコメントを表示
I want to create a simple histogram of the data in a matrix, though when I use hist(matrix), the figure that is created consists of numerous rainbow-colored bars, which though they are in the general shape of a histogram are not what I need. For this dataset, I only want a maximum of 31 bars. How might I get a simple, standard, single-hued histogram instead of the complex, multi-colored version that I described?
0 件のコメント
採用された回答
per isakson
2012 年 11 月 27 日
編集済み: per isakson
2012 年 11 月 27 日
Convert the matrix to a vector:
hist( matrix(:) )
and read the documentation on hist once more.
0 件のコメント
その他の回答 (0 件)
参考
カテゴリ
Help Center および File Exchange で Histograms についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!