# Difference between revisions of "Eleisha's Segment 41: Markov Chain Monte Carlo, Example 2"

Line 2: | Line 2: | ||

1. Show that the waiting times (times between events) in a Poisson process are Exponentially distributed. (I think we've done this before.) | 1. Show that the waiting times (times between events) in a Poisson process are Exponentially distributed. (I think we've done this before.) | ||

− | The waiting time to the kth event in a Poisson process with rate <math>\lambda </math> is distributed a <math>\text{Gamma}(k, \lambda) </math> | + | The waiting time to the kth event in a Poisson process with rate <math>\lambda </math> is distributed a <math>\text{Gamma}(k, \lambda) </math>. |

+ | Let <math>\Tau = t_{i+k - t_i}</math> with <math>\Tau </math> = time from event i to event k. | ||

+ | |||

+ | So in this case <math> <math>\Tau = t_{i+1 - t_i}</math> where <math> \Tau </math> is the time from the first event to a second event | ||

+ | |||

2. Plot the pdf's of the waiting times between (a) every other Poisson event, and (b) every Poisson event at half the rate. | 2. Plot the pdf's of the waiting times between (a) every other Poisson event, and (b) every Poisson event at half the rate. |

## Revision as of 17:35, 9 May 2014

**To Calculate: **

1. Show that the waiting times (times between events) in a Poisson process are Exponentially distributed. (I think we've done this before.)
The waiting time to the kth event in a Poisson process with rate **Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle \lambda }**
is distributed a **Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle \text{Gamma}(k, \lambda) }**
.
Let **Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle \Tau = t_{i+k - t_i}}**
with **Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle \Tau }**
= time from event i to event k.

So in this case **Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle <math>\Tau = t_{i+1 - t_i}}**
where **Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle \Tau }**
is the time from the first event to a second event

2. Plot the pdf's of the waiting times between (a) every other Poisson event, and (b) every Poisson event at half the rate.

3. Show, using characteristic functions, that the waiting times between every Nth event in a Poisson process is Gamma distributed. (I think we've also done one before, but it is newly relevant in this segment.)

**To Think About: **

1. In slide 5, showing the results of the MCMC, how can we be sure (or, how can we gather quantitative evidence) that there won't be another discrete change in **Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle k_1}**
or **Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle k_2}**
if we keep running the model longer. That is, how can we measure convergence of the model?

2. Suppose you have two hypotheses: H1 is that a set of times **Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle t_i}**
are being generated as every 26th event from a Poisson process with rate 26. H2 is that they are every 27th event from a Poisson process with rate 27. (The mean rate is thus the same in both cases.) How would you estimate the number **Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle N }**
of data points **Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle t_i}**
that you need to clearly distinguish between these hypotheses?

**Back To: ** Eleisha Jackson