<p>In my question, I rewrite the joint probability as the product of the conditionals probabilities but I wrongly implemented the markov assumption of this model. The markov assumption is:
$$
p(s_{t}=j|s_{t-1}=i,\Omega_{t-1})=p(s_{t}=j|s_{t-1}=i)=p_{ij}
$$
But, when conditioned to information available at date t
$$
p(s_{t}=j|s_{t-1}=i,\Omega_{t})\neq p(s_{t}=j|s_{t-1}=i)=p_{ij}
$$
Meaning that</p>

<p>$$
p(s_{t}=j,s_{t-1}=i|\Omega_{t})\neq p(s_{t}=j|s_{t-1}=i)p(s_{t-1}=i|\Omega_{t})
$$</p>

CC BY-SA 3.0
2015-07-30T17:46:57.283Z
2015-07-30T17:46:57.283Z
anfego
<p>I'm an undergraduate student and I'm trying to code the specification testing for Markov-switching model in R, based on the article "Specification Testing in Markov-Switching time series models" <a href="http://www.sciencedirect.com/science/article/pii/0304407669416869" rel="nofollow">Hamilton</a> 1996.</p>

<p>More specifically, I don't understand equation 3.12, or maybe I have misunderstood something. </p>

<p>In equation 3.12 you have a term like this </p>

<p>$$ = p_{ij}^{-1} p(s_{t}=j,s_{t-1}=i|\Omega_{t})$$</p>

<p>But since </p>

<p>$$ p(s_{t}=j,s_{t-1}=i|\Omega_{t}) = p_{ij} p(s_{t-1}=i|\Omega_{t})$$</p>

<p>then </p>

<p>$$= p_{ij}^{-1}p_{ij} p(s_{t-1}=i|\Omega_{t}) = p(s_{t-1}=i|\Omega_{t})$$</p>

<p>Is this ok? </p>

CC BY-SA 3.0
2014-12-16T07:38:29.700Z
Hi - your question is pretty broad and I think it would do better to narrow it down. Besides, just giving a name and a reference might be enough, but it looks sloppy and like you can't be bothered.
Thorst
CC BY-SA 3.0
2014-12-16T11:48:34.660Z
The Hamilton paper is a 30-page, 50-numbered-equations paper, dealing with the fine art and science of specification testing. It belongs to that stage in science where there are no "easy explanations" anymore. It is encouraging for the state of Economics education that it was assigned in the context of an undergraduate thesis, but you have to... "do the crime and do the time", form your prison-break plan, and then ask us about specific details on it.
Alecos Papadopoulos
CC BY-SA 3.0
2014-12-16T20:51:32.677Z
Ok fine, no easy explanation, I was wondering if you know an article that make a detail explanation of this article.
anfego
<econometrics>
Trouble understanding hamilton 1996 specification testing in MS
anfego
# Trouble understanding hamilton 1996 specification testing in MS

(Asked by: username_0 on 2014-12-16)

I'm an undergraduate student and I'm trying to code the specification testing for Markov-switching model in R, based on the article "Specification Testing in Markov-Switching time series models" [Hamilton](http://www.sciencedirect.com/science/article/pii/0304407669416869) 1996.

More specifically, I don't understand equation 3.12, or maybe I have misunderstood something.

In equation 3.12 you have a term like this

$$ = p\_{ij}^{-1} p(s\_{t}=j,s\_{t-1}=i|\Omega\_{t})$$

But since

$$ p(s\_{t}=j,s\_{t-1}=i|\Omega\_{t}) = p\_{ij} p(s\_{t-1}=i|\Omega\_{t})$$

then

$$= p\_{ij}^{-1}p\_{ij} p(s\_{t-1}=i|\Omega\_{t}) = p(s\_{t-1}=i|\Omega\_{t})$$

Is this ok?

**Tags:** econometrics

> **Comments:**
> **username_1**: Hi - your question is pretty broad and I think it would do better to narrow it down. Besides, just giving a name and a reference might be enough, but it looks sloppy and like you can't be bothered.  
> **username_2**: The Hamilton paper is a 30-page, 50-numbered-equations paper, dealing with the fine art and science of specification testing. It belongs to that stage in science where there are no "easy explanations" anymore. It is encouraging for the state of Economics education that it was assigned in the context of an undergraduate thesis, but you have to... "do the crime and do the time", form your prison-break plan, and then ask us about specific details on it.  
> **username_0**: Ok fine, no easy explanation, I was wondering if you know an article that make a detail explanation of this article.  

---

## 1 answers

### Answer by username_0 on 2015-07-30. Score: 1 | Accepted answer

In my question, I rewrite the joint probability as the product of the conditionals probabilities but I wrongly implemented the markov assumption of this model. The markov assumption is:
$$
p(s\_{t}=j|s\_{t-1}=i,\Omega\_{t-1})=p(s\_{t}=j|s\_{t-1}=i)=p\_{ij}
$$
But, when conditioned to information available at date t
$$
p(s\_{t}=j|s\_{t-1}=i,\Omega\_{t})\neq p(s\_{t}=j|s\_{t-1}=i)=p\_{ij}
$$
Meaning that

$$
p(s\_{t}=j,s\_{t-1}=i|\Omega\_{t})\neq p(s\_{t}=j|s\_{t-1}=i)p(s\_{t-1}=i|\Omega\_{t})
$$


---

