フィルターのクリア

Evaluate the "goodness of fit" of a distribution fitting, when using the function "fitdist"

33 ビュー (過去 30 日間)
Sim
Sim 2023 年 6 月 14 日
コメント済み: Mathieu NOE 2023 年 6 月 22 日
When I use the function fitdist to find the best distribution fitting, I would like to measure or assess the goodness of fitting.
What are the possible ways to measure the goodness of fitting of a distribution fitting, when employing the function fitdist?
% Example where I would like to assess the goodness of fit for this
% histogram:
rng default;
r = normrnd(10,10,1000,1);
histogram(r,'binwidth',1,'Normalization','pdf') % <-- my data
pd = fitdist(r,'normal'); % <-- fit the distribution to the data (fitdist)
xgrid = linspace(-30,100,100)';
pdfEst = pdf(pd,xgrid);
line(xgrid,pdfEst,'Linewidth',2,'color','r')
  7 件のコメント
Sim
Sim 2023 年 6 月 22 日
Thanks a lot @Mathieu NOE, that's great! .....I did not think about the R2 for this case..... :-)

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

回答 (0 件)

Community Treasure Hunt

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

Start Hunting!

Translated by