Let $X_{n} \xrightarrow{P} X$ and $f: \mathbb R \to \mathbb R$ be uniformly continuous. Show that $f(X_{n}) \xrightarrow{P} f(X)$
My idea:
Let $\epsilon > 0$, there then exists $\delta > 0$. Since $X_{n} \xrightarrow{P}X$, it follows that $\exists N \in \mathbb N$ such that $|X_{n}-X|\geq\delta$ has $P-$measure $0$, $\forall n \geq N$. This means that $|X_{n}-X|< \delta$ has $P-$measure $1$, $\forall n \geq N$
Since $|X_{n}-X|< \delta$ and from the uniform continuity of $f$ we see that:
$|f(X_{n})-f(X)|<\epsilon$ for all $n \geq N$ and has $P-$measure $1$, and therefore $P(|f(X_{n})-f(X)|\geq \epsilon)=1-P(|f(X_{n})-f(X)|<\epsilon)=0$, $\forall n \geq N$.
Thus $\lim_{n \to \infty}P(|f(X_{n})-f(X)|\geq \epsilon)$, $\forall \epsilon > 0$
and so $f(X_{n})\xrightarrow{P}f(X)$.
Somehow, I do not believe that this proof is correct. Any ideas how to improve it?
Convergence in probability says that for every $\delta>0$,$$ \Bbb P(|X_n-X|\ge \delta)\xrightarrow{n\to\infty} 0, $$but not that there exists $N$ such that $\Bbb P(|X_n-X|\ge \delta)=0$ for every $n\ge N$. This is where you went wrong. However, this does not pose much difficulty as we can control both terms in $$ \Bbb P(|f(X_n)-f(X)|\ge \epsilon, |X_n-X|\ge \delta)+\Bbb P(|f(X_n)-f(X)|\ge \epsilon, |X_n-X|< \delta) $$ by careful analysis.
Note: But, actually, what we need is only the continuity of $f$ to have that $f(X_n)\rightarrow_pf(X).$ To see this, it takes much less effort to use another characterization of convergence in probability. In fact, $X_n \rightarrow_p X$ is equivalent to saying that for every subsequence $n(k)$, there exists a subsubsequence $n(k(r))$ such that $X_{n(k(r))} \xrightarrow{r\to\infty} X\text{ a.s.}$ Using this criterion and the continuity of $f$, we can find that every subsequence $n(k)$ admits a subsubsequence $n(k(r))$ such that $$ f(X_{n(k(r))})\xrightarrow{r\to\infty} f(X)\ \ \text{ a.s.} $$ That is, $f(X_n)\longrightarrow_p f(X)$.