How to extract x and y data from fitted curve of a histogram?

6 ビュー (過去 30 日間)
Imam
Imam 2014 年 8 月 27 日
コメント済み: Walter Roberson 2017 年 2 月 22 日
I have a set of data represented in histogram. I also add a curve fitting onto the histogram of the kind histfit(data,nbins,dist). My goal is to extract the x (horizontal) and y (vertical) values of the fitted curve. I can do that by first saving the picture in .fig format and use 'openfig' command to call it again and use 'get', but I don't want to do that. I want to directly extract the x and y data from one matlab file. How do I do that?

採用された回答

Chad Greene
Chad Greene 2014 年 8 月 27 日
h = histfit(...) returns a vector of handles h, where h(1) is the handle to the histogram and h(2) is the handle to the density curve.
  3 件のコメント
Imam
Imam 2014 年 8 月 27 日
Perfectly what I want. Thanks a lot Chad.
Walter Roberson
Walter Roberson 2017 年 2 月 22 日
imu931 comments to Chad Greene:
Very helpful! Thx!

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

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeHistograms についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by