Let $I\subset \mathbb{R}$ be an interval. By definition $\text{diam}f(I)=\sup_{x, x'\in I}|f(x)-f(x')|$, $\text{osc}(f, I)=\sup_{x\in I}f(x)-\inf_{x\in I}f(x)$ and $\text{osc}(f, x_0)=\lim_{\epsilon\to 0}\text{osc}(f, B_{\epsilon}(x_0))$.
Is it true that $$\text{diam}f(I)=\text{osc}(f, I)$$ and $$\text{osc}(f, x_0)=\inf\{\text{osc}(f, B_{\delta}(x_0)):\delta>0\}=\limsup_{x\to x_0}f(x)-\liminf_{x\to x_0}f(x)$$ ? I think so but I want to be sure.