MATLAB: Fitting Distributions to data from a Monte Carlo Simulation

MATLABmodelstatisticsStatistics and Machine Learning Toolbox

Hi all,
I have a question related to statistical sampling. I have seen that 'Allfitdist' (<allfitdist>) helps to test the fit of different distributions for a defined set of data, but is there a tool that evaluate selected distribution fits (like 'Allfitdist'), but also chooses an optimal fit and quotes the goodness of fit (might sound like too much..xD)? Would really appreciate any help.

Best Answer

See fitdist(): https://www.mathworks.com/help/releases/R2020a/stats/fitdist.html. It allows to choose from a list of distribution. Also check mle(): https://www.mathworks.com/help/releases/R2020a/stats/mle.html