How to incorporate likelihood component in posterior estimation?

2 visualizaciones (últimos 30 días)
Moto
Moto el 18 de Ag. de 2023
Respondida: the cyclist el 18 de Ag. de 2023
Hi, I'm new to Matlab and as such I have a very basic question to ask about posterior estimation. In the Bayes Theorem, posterior distribution is proportional to the product of (a) Conditional probability of observing data conditional on parameters (i.e., likelihood function) and (b) Prior distribution of parameters. I understand the Prior part can be dealt with command line like " bayeslm(p,'ModelType','conjugate',..) ". However, I have difficulties how to incorporate likelihood function component. I tried something like " bayeslm(p,'ModelType','conjugate',..)*normpdf(y,mu,sigma) "; however, it didn't work. I appreciate any thoughts. Sorry to address a basic question like this.

Respuestas (1)

the cyclist
the cyclist el 18 de Ag. de 2023
I am not experienced using these models, but based on the workflow described in this documentation, I think you just need to use the PriorMdl object (that is the output of bayeslm) as an input to the estimate function (along with the new data), to get the estimated posterior distribution. You don't need to "manually" calculate it via the likelihood function.

Productos


Versión

R2023a

Community Treasure Hunt

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

Start Hunting!

Translated by