Question: Problem 3 . 2 In this problem, we numerically calculate a posterior distribution. Suppose the stimulus distribution p s ( s ) is Gaussian with

Problem 3.2 In this problem, we numerically calculate a posterior distribution. Suppose the
stimulus distribution ps(s) is Gaussian with mean 20 and standard deviation 4. The measurement
distribution px|s(x|s) is Gaussian with standard deviation =5. A Bayesian observer infers s from
an observed measurement xobs=30. We are now going to calculate the posterior probability density
using numerical methods.
a) Define a vector of hypothesized stimulus values s:(0,0.2,0.4,dots,40).
b) Compute the likelihood function and the prior on this vector of s values.
c) Multiply the likelihood and the prior pointwise.
d) Divide this product by its sum over all s(normalization step).
e) Convert this posterior probability mass function into a probability density function by dividing
by the step size you used in your vector of s values (e.g.,0.2).
f) Plot the likelihood, prior, and posterior in the same plot.
g) Is the posterior wider or narrower than likelihood and prior? Do you expect this based on the
equations we discussed?
h) Change the standard deviation of the measurement distribution to a large value. What happens
to the posterior? Can you explain this?
i) Change the standard deviation of the measurement distribution to a small value. What
happens to the posterior? Can you explain this?
 Problem 3.2 In this problem, we numerically calculate a posterior distribution.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Mathematics Questions!