L aTeX+表格的处理精品参考资料.docVIP

  • 8
  • 0
  • 约4.79千字
  • 约 6页
  • 2017-02-02 发布于江苏
  • 举报
LaTeX 表格的处理 LaTeX 表格处理概述 一般三线表的处理 带表格注释的三线表 固定列宽和自动伸缩列宽 固定列宽与对齐方式 自动伸缩列宽 跨页表格 表格旋转和后置 表格旋转 表格后置 辅助转换工具 LaTeX 表格处理概述 与 word 不同,LaTeX 通过一定的语法规则将表格写成纯文本形式。基本规则包括:表格从上到下,每一行从左到右,单元格内容使用 分隔,用 \\ 换行。最基本的表格环境是 tabular 环境。下面是一个简单的表格代码和实际效果: \begin{tabular}[t]{l|c} \hline 姓名 年龄 \\ \hline 张三 32 \\ 李四 12 \\ 王五 24 \\ \hline \end{tabular} 一般三线表的处理 学术论文普遍使用三线表。三线表的特点主要是:整个表格通常只有三条横线,首尾两条横线较粗,中间一条较细,一般不使用竖线。LaTeX 处理三线表相当简单方便。用到的宏包主要是 booktabs 。下面是普通三线表的代码和效果: \begin{table}[htbp] \caption{\label{tab:test}示例表格} \begin{tabular}{lcl} \toprule 姓名 年龄 地址\\ \midrule 张三 32 中华人民共和国\\ 李四 12 中华人民共和国\\ 王五 24 中华人民共和国\\ \bottomrule \end{tabular} \end{table} 带表格注释的三线表 三线表有时候还需要加上注释以便给出表格的资料来源等信息。解决这一问题可以使用下面三个办法之一: 使用 ctable 宏包。该宏包用法简单,下面是典型代码和效果: \ctable[% caption=The Skewing Angles, label=tab:nowidth, ]{lcc} {\tnote{for the abstraction reaction, $Mu+HX \rightarrow MuH+X$.} \tnote[b]{1 degree${} = \pi/180$ radians.} \tnote[c]{this is a particularly long note, showing that footnotes are set in raggedright mode as we dont like hyphenation in table footnotes.} } {\FL $H(Mu)+F_2$ $H(Mu)+Cl_2$ \ML $\beta$(H) $80.9$\tmark[b] $83.2$ \NN $\beta$(Mu) $86.7$ $87.7$ \LL } 使用 threeparttable 宏包。下面是典型代码和效果: \begin{table}[htbp] \centering\small \begin{threeparttable} \caption{\label{tab:results}Effect of Trade Openness on Environment (Air Pollution)} \begin{tabular}{lccc} \toprule NO$_2$ SO$_2$ PM \\ \midrule $\ln(y/pop)$ 408.74* 287.25* 566.65 \\ (121.79) (118.81) (336.19) \\ $\ln(y/pop)^2$ $-$22.85* $-$16.58* $-$35.57** \\ (6.90) (6.78) (19.06) \\ $(X+M)/Y$ $-$.29** $-$.31* $-$.37 \\ (.17) (.08) (.34) \\ $Polity$ $-$3.20* $-$6.58* $-$6.70** \\ (1.47) (2.05) (3.42) \\ $\ln(LandArea/pop)$ $-$5.94 $-$2.9

文档评论(0)

1亿VIP精品文档

相关文档