用箭头和文本框解释表格

用箭头和文本框解释表格

我正在尝试转换使用箭头和文本框解释的表格,但不知道从哪里开始。我没有一个可行的示例,对此我深感抱歉。我在网站上没有看到过类似的东西,主要是带有箭头的表格指向某些单元格。这种情况完全不同。下面的图片是我需要做的。任何帮助都将不胜感激,谢谢。

在此处输入图片描述

答案1

作为起点:

\documentclass[tikz, margin=3mm]{standalone}
\usetikzlibrary{arrows.meta, 
                matrix,
                positioning,
                tikzmark}

\begin{document}
    \begin{tikzpicture}[
node distance = 7mm and 1mm,
   box/.style = {draw, align=left},                
   arr/.style = {-Stealth, semithick, shorten >=2pt, shorten <=2pt},
                    ]
\matrix (m) [matrix of nodes,
               nodes={draw, minimum height=4ex, text depth=0.25ex, 
                      text width=8em, align=center, anchor=north},
         column sep=-\pgflinewidth,
            row sep=-\pgflinewidth,
             ]
{
\textbf{Currency Pair}  & \textbf{Buying Rate}  & \textbf{Selling Rate} \\
USD/SGD                 & 1.4550                & 14650                 \\
};
\node (a1) [box, above  left=of m-1-2.north]    {You give bank 1 USD\\
                                                 they give you 1.455 SGD};
\node (a2) [box, above right=of m-1-3.north]    {You give bank 1.456 SGD\\
                                                 they give you 1 USD};
\draw[arr]  (m-1-2) edge (a1)
            (m-1-3) edge (a2);
\node[above=0mm of m-1-1.north,
      font=\tiny] {\underline{For illustration purpose only}};
%
\node (b1) [box, below  left=of m-2-1.south]    {This is Base Currency};
\node (b2) [box, below right=of m-2-1.south]    {This is Counter Currency};
\draw[arr,shorten <=-5pt]   (m-2-1) edge (b1)
                            (m-2-1) edge (b2);
    \end{tikzpicture}
\end{document}

在此处输入图片描述

相关内容