Can I find likelihood function of an objective function?

4 ビュー (過去 30 日間)
Miraboreasu
Miraboreasu 2022 年 11 月 28 日
回答済み: Jeff Miller 2022 年 11 月 29 日
Sorry this is not a question 100% related to MATLAB.
I have some data. I used
nlinfit
and got the parameters for these three functions (model), as well as MSE
$f_1=b1*x1+b2*x2+b3$
$f_2=b1*x1^b2+b3*x2+b4$
$f_3=b1*x1^b2+b3*x2^b4+b5$
Besides comparing their MSE, I read some model selection method, but they need maximized value of the likelihood function for the model. What I know about liklihood is for some data with dirstributions
So is there a way or is that ok to find likelihood function for f1, f2, and f3?

回答 (2 件)

Star Strider
Star Strider 2022 年 11 月 28 日
If you have the Statistics and Machine Learning Toolbox, see if the mle function (and associated functions) will do what you want. It estimated the parameters of a probability distribution. There are several to choose from, dependong on how your data are distributed.
Search the documentation for ‘likelihood’ for all the functions that mention it.

Jeff Miller
Jeff Miller 2022 年 11 月 29 日
A lot depends on the details of these models, but one way to proceed would be in terms of the error scores. Consider the full model to be
$f_1=b1*x1+b2*x2+b3 + e_{1i}$
where is the residual for case i according to model 1 (and similarly for models 2 & 3). If you assume that the e values are normally distributed with mean 0 and some unknown variance (as I believe would be appropriate for some models), then you can use the computed e values for each model to get the maximum likelihood estimate of for that model, compute the likelihood of each e value within the model's estimated normal(0, ) distribution, and finally compute the likelihood of the whole dataset under the model as the product of the likelihood values of the individual e's.
Looking at the models this way, the only random values are the e's, so they are the only quantities relevant to the computation of likelihood.
HTH,

タグ

製品


リリース

R2022a

Community Treasure Hunt

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

Start Hunting!

Translated by