If we have $X$ with a density depending on the scalar parameter $\theta$, where the density is from of the exponential family: $f(x;\theta) = \exp(\theta x−\phi(\theta))h(x)$.

Also we have that $\theta$ has prior density $\pi(\theta)$. How would I calculate the conditional expectation of parameter, $\mathbb{E}(\theta | x)?$

I have tried to find the posterior and get the expectation that way, but I couldn't get a nice solution. I have also tried to calculate it using the integral definition and also get stuck.

  • $\begingroup$ It depends on the prior distribution, hence there is no generic answer to the question and no analytic formula for most choices of the prior distribution. $\endgroup$ – Xi'an Nov 11 '20 at 11:04