# Higlight an effect in an equation using underset in combination with xleftarrow

I would like to highlight a certain effect in an equation using either underbrace or underset in combination with xleftarrow. However, I am not very satisfied with the result of underbrace as you can see in my MWE. The result of using underset in combination with xleftarrow is also not satisfying because there is a lot of white space between the "F" and "E" (See MWE).

In case of the latter, I just would like to have an arrow below the text "Fed_t" pointing to the left hand side of equation (3). When this is done in a way that there is no extra space between letters, I think it is the best option to highlight what I want. Anyone who can help me with this?

Other suggestions to highlight the effect of "Fed_t" to the left hand side of equation 3 are also very welcome!

MWE:

\documentclass[table]{beamer}
\usepackage[english]{babel}
\usepackage[utf8]{inputenc}
\usepackage{amsmath}
\usepackage{mathtools}
\let\underbrace\LaTeXunderbrace
\let\overbrace\LaTeXoverbrace
\begin{document}
\begin{frame}
\frametitle{Methodology}
\framesubtitle{General framework}
In the case of the eurozone:
\begin{aligned} \underbrace{\Delta R^n_t = f (Fed_t}_{\text{Fed signalling effect}}, ECB_t, News_t ) \\ \end{aligned}
\begin{itemize}
\item Fed UMP announcements $\Rightarrow$ $\Delta R^n_{t}$, $\Delta TPP^n_t$ and  $\Delta TPR^n_t$. First, cancel out the effects through signalling:
\end{itemize}
\begin{aligned} \Delta(Y^n_t - R^n_t)= \Delta TPP^n_t + \Delta TPR^n_t \\ \end{aligned}
In case of the eurozone:
\begin{aligned} \Delta(Y^n_t - R^n_t) = f (\underset{\xleftarrow[\text{Fed signalling}]{}} Fed_t , ECB_t, News_t, Sovereign_t) \\ \end{aligned}
\end{frame}
\end{document}


This matches the \underbrace you had in the first example:

\documentclass[table]{beamer}
\usepackage[english]{babel}
\usepackage[utf8]{inputenc}
\usepackage{amsmath}
\usepackage{mathtools}

\begin{document}

\begin{frame}
\frametitle{Methodology}

In case of the eurozone:
$${\mathop{ \underleftarrow{\Delta(Y^n_t - R^n_t) = f (Fed_t} }_{\text{Fed signalling effect}}}, ECB_t, News_t, Sovereign_t)$$

\end{frame}

\end{document}


An understack, with the\useanchorwidth parameter set T will not let the size of the understacked material affect the spacing of the the stack's "anchor".

\documentclass[table]{beamer}
\usepackage[english]{babel}
\usepackage[utf8]{inputenc}
\usepackage{amsmath}
\usepackage{mathtools}
\usepackage{stackengine}
\stackMath
\let\underbrace\LaTeXunderbrace
\let\overbrace\LaTeXoverbrace
\begin{document}
\begin{frame}
\frametitle{Methodology}
\framesubtitle{General framework}
In the case of the eurozone:
\begin{aligned} \underbrace{\Delta R^n_t = f (Fed_t}_{\text{Fed signalling effect}}, ECB_t, News_t ) \\ \end{aligned}
\begin{itemize}
\item Fed UMP announcements $\Rightarrow$ $\Delta R^n_{t}$, $\Delta TPP^n_t$ and  $\Delta TPR^n_t$. First, cancel out the effects through signalling:
\end{itemize}
\begin{aligned} \Delta(Y^n_t - R^n_t)= \Delta TPP^n_t + \Delta TPR^n_t \\ \end{aligned}
In case of the eurozone:
\begin{aligned} \Delta(Y^n_t - R^n_t) = f (\stackengine{3pt}{Fed_t}{% \scriptstyle\xleftarrow[\text{Fed signalling}]{}}{U}{c}{F}{T}{S} , ECB_t, News_t, Sovereign_t) \\ \end{aligned}
\end{frame}
\end{document}


Alternately, you can use a \mathclap to achieve essentially the identical result:

\begin{aligned}
\Delta(Y^n_t - R^n_t) =  f (\underset{\mathclap{\xleftarrow[
\text{Fed signalling}]{}}} {Fed_t} , ECB_t, News_t, Sovereign_t) \\
\end{aligned}


To answer the OP's comment below, to get right alignment of the arrow under the FED_t, one can use

\begin{aligned}
\Delta(Y^n_t - R^n_t) =  f (\stackengine{5pt}{Fe}{%
\scriptstyle\xleftarrow[\text{Fed signalling}]{}}{U}{r}{F}{T}{S}d_t ,
ECB_t, News_t, Sovereign_t) \\
\end{aligned}


This was achieved by changing the c alignment of the stack to r alignment; making that alignment occur after Fe rather than after Fed_t; and increasing the stackunder gap to 5pt.

• Thanks for your quick reply and good answer. However, in case of useanchorwidth, how can the arrow be more placed to the left? So that it starts in the middle of Fed and points towards the left hand side? (now it starts below ECB) – peter Jan 25 '17 at 13:27
• @peter There are two things: 1) change the c argument of \stackengine to r for right alignment; and 2) instead up putting Fed_t as the 2nd argument to \stackengine, just put Fe, and place the d_t after the last \stackengine argument. I will edit my answer to show it. – Steven B. Segletes Jan 25 '17 at 14:11