How do I Plot density probability values over a histogram as colormap?

2 ビュー (過去 30 日間)
Saeed Mohammadian
Saeed Mohammadian 2018 年 6 月 6 日
コメント済み: Saeed Mohammadian 2018 年 6 月 6 日

I have a histogram as follows:

First, I want to know how to plot probability density values as colormap over it.

second, is there any way I can retreive X_data versus corresponding normalized frequency as two separate vectors?

Thanks

採用された回答

Image Analyst
Image Analyst 2018 年 6 月 6 日
I don't know what "plot probability density values as colormap over it." means. Please attach a screenshot of what you'd like to see.
The histogram() function returns an object that has the x values (bin edges), as well as the y values (counts) and a whole bunch of other things. Look at is in the variable editor.
histObject = histogram(yourData)
  2 件のコメント
Image Analyst
Image Analyst 2018 年 6 月 6 日
You can get the handle to each bar and change it's color. See attached demo.
Saeed Mohammadian
Saeed Mohammadian 2018 年 6 月 6 日
Thanks a lo that's a great help
Saeed

サインインしてコメントする。

その他の回答 (1 件)

Saeed Mohammadian
Saeed Mohammadian 2018 年 6 月 6 日
Thank you very much
What I'm actually looking for to plot the frequency, or normalized frequncys as color on each bean. Not sure if it has a readily available function or I need to develop my own.
COnsider the following cdf histogram:
I just want to color each bean with its associated value for better illustration purposes. Is it possible to do so?

カテゴリ

Help Center および File ExchangeData Distribution Plots についてさらに検索

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by