Lecture 2#
Likelihood Function#
Assuming a gaussian error distribution for the data,
Markov Chain Monte Carlo (MCMC)#
A method to sample the posterior \(P(\theta | D)\).
MCMC Hasting#
Begin with starting point \(\theta_0\)
Propose \(\theta_{t+1}\) based on sampling a random proposal distribution \(J(\theta_{t+1} \mid \theta_t)\).
Keep it with a probability proportional to if it improves the posterior ratio else try again:
\[\frac{P(\theta_{t+1} | D)}{P(\theta_{t} | D)}\]
Affine Invariant MCMC#
Adding multiple samplers (aka walkers) we group each walk as a pairs. The next step step for a walker is towards its partner’s line of sight. A new partner is assigned at every step.
Goodness of Fit#
Geweke Score:
Take the end and begining of the chain and computer the score as, $\( \frac{\bar \theta_e - \bar \theta_b}{\sqrt{\text{Var}[\theta_e]\text{Var}[\theta_b]}} \)$
G-R Statistics
Acceptance Fraction
Autocorrelation Function
Typicall have burn-in period 5 times larger than the ACF convergence number.
Periodogram#
A periodogram can be produced by a fourier transform of some time-series data:
When plotting a periodogram, we often plot the power spectrum over frequency,
Pratically, an unbounded infinite signal is not possible thus we apply whats called fast fourier transform,
\(\Delta t\) : Sampling interval.
In irregular sampling interval you get the Lomb-Scargle Periodogram. To model data with a single frequency,