필터 지우기
필터 지우기

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

조회 수: 33 (최근 30일)
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