2012年11月7日水曜日

TeXの表の下に脚注をつける

TeXで表のすぐ下に脚注を、脚注ライン抜きでつける方法。
http://www.biwako.shiga-u.ac.jp/sensei/kumazawa/tex/threeparttable.html
http://www.latex-community.org/viewtopic.php?f=5&t=929
参照。

preambleに
\usepackage{threeparttable}
と書く。表と脚注は以下。

\begin{table}
\begin{center}
\caption{hogehoge}
\label{hogehoge}
\begin{threeparttable}
\begin{tabular}{cc}\hline
1 \tnote{1} & 2 \tnote{2} \\
2 \tnote{a} & 4 \\ \hline
\end{tabular}
\begin{tablenotes}\footnotesize
\item[1] one
\item[2] two
\item[a] three
\end{tablenotes}
\end{threeparttable}
\end{center}
\end{table}

threeparttableのパッケージを導入して、table環境の中でthreeparttable環境始める。普通にtablular始めて、脚注つけたいところ\tnote{}をつける。{}の中身は脚注番号として出る。1なら1、aならa。でtablular閉じた後にtablenotes環境を始めて\item[]で脚注。[]の中身はtnoteと対応づける。あとはthreeparttable環境閉じる。キャプションとラベル、centerは普通と同じ。

表の下に脚注つける方法でググるとminipage環境をtable環境の中で作ってそこで\footnoteでつけることができるってあるけど、それだと表の下のラインにまた脚注ラインが出て美しくない。

0 件のコメント:

コメントを投稿