请帮助解决以下问题。我正在尝试将表格注释添加到表格中。一旦我将它们添加到表格上方,我就会收到以下错误:“!软件包图形错误:除以 0。”。下面我附上了我使用的所有软件包和表格本身:
软件包:
\documentclass[12pt]{article}
\usepackage[english]{babel}
%\usepackage[utf8x]{inputenc}
\usepackage[mincitenames=1,maxcitenames=2,authordate, backend=biber, natbib]{biblatex-chicago}
%\usepackage[authordate, backend=biber, natbib]{biblatex-chicago}
\usepackage{appendix}
\usepackage[capposition=top]{floatrow}
\usepackage{multirow}
\usepackage{amsmath}
\usepackage{mathtools}
\usepackage{lipsum}
% package for including graphics with figure-environment
\usepackage{graphicx}
\usepackage[normalem]{ulem}
%\usepackage{hyperref}
\usepackage{multirow}
\usepackage{setspace}
\usepackage{breqn}
\usepackage[paper=portrait,pagesize]{typearea}
\usepackage{rotating}
%\usepackage{fontspec}
%\setmainfont{Times New Roman}
\usepackage{float}
\usepackage{rotating}
\usepackage[flushleft]{threeparttable}
\usepackage{array}
\usepackage{lscape}
\usepackage{booktabs}
\usepackage{adjustbox}
\usepackage{tabularx}
\usepackage{titlesec}
\usepackage[colorlinks=true,citecolor=blue]{hyperref}
\addbibresource{Reference.bib}
\usepackage{bm}
\usepackage{blindtext}
\usepackage{multicol}
\usepackage{ragged2e}
\usepackage{mathtools}
\usepackage{fancyvrb}
\usepackage{subcaption}
\usepackage{supertabular}
\usepackage[labelfont=bf]{caption}
\captionsetup{justification = raggedright,
singlelinecheck = false}
\usepackage{makecell}
****桌子**
\newpage
\centering
\begin{table}[H]
\bigskip
\centering
\begin{adjustbox}{height=0.45\textheight}
\begin{threeparttable}
\footnotesize
\centering
\begin{tablenotes}
\footnotesize
\item This table presents results of a model:
\end{tablenotes}
\begin{tabular}{lccccc} \hline
\multicolumn{5}{l}{\textbf{Panel A:} Bank loans}\\
& & & & \\\hline
&\multicolumn{4}{c}{Bank Loans} &Bond Market \\
\cmidrule[0.4pt](r{0.125em}){2-5}%
\cmidrule[0.4pt](r{0.125em}){6-6}% \\
& (1) & (2) & (3) & (4) & (5) \\
VARIABLES & a& b& c & d & e \\ \hline
& & & & & \\
\hline\hline
\end{tabular}
\end{threeparttable}
\end{adjustbox}
\end{table}
答案1
该问题与表格周围有关adjustbox
,但无论如何,您都不应缩放包含文本的元素(为什么不缩放包含文本的元素),因此只需将其删除即可。
\documentclass[12pt]{article}
\usepackage[english]{babel}
%\usepackage[utf8x]{inputenc}
\usepackage[mincitenames=1,maxcitenames=2,authordate, backend=biber, natbib]{biblatex-chicago}
%\usepackage[authordate, backend=biber, natbib]{biblatex-chicago}
\usepackage{appendix}
\usepackage[capposition=top]{floatrow}
\usepackage{multirow}
\usepackage{amsmath}
\usepackage{mathtools}
\usepackage{lipsum}
% package for including graphics with figure-environment
\usepackage{graphicx}
\usepackage[normalem]{ulem}
%\usepackage{hyperref}
\usepackage{multirow}
\usepackage{setspace}
\usepackage{breqn}
\usepackage[paper=portrait,pagesize]{typearea}
\usepackage{rotating}
%\usepackage{fontspec}
%\setmainfont{Times New Roman}
\usepackage{float}
\usepackage{rotating}
\usepackage[flushleft]{threeparttable}
\usepackage{array}
\usepackage{lscape}
\usepackage{booktabs}
\usepackage{adjustbox}
\usepackage{tabularx}
\usepackage{titlesec}
\usepackage[colorlinks=true,citecolor=blue]{hyperref}
\addbibresource{Reference.bib}
\usepackage{bm}
\usepackage{blindtext}
\usepackage{multicol}
\usepackage{ragged2e}
\usepackage{mathtools}
\usepackage{fancyvrb}
\usepackage{subcaption}
\usepackage{supertabular}
\usepackage[labelfont=bf]{caption}
\captionsetup{justification = raggedright,
singlelinecheck = false}
\usepackage{makecell}
\begin{document}
\newpage
\centering
\begin{table}[H]
\bigskip
\centering
% \begin{adjustbox}{height=0.45\textheight}
\begin{threeparttable}
\footnotesize
\centering
\begin{tablenotes}
\footnotesize
\item This table presents results of a model:
\end{tablenotes}
\begin{tabular}{@{}lccccc@{}} \hline
\multicolumn{5}{@{}l@{}}{\textbf{Panel A:} Bank loans}\\
& & & & \\\hline
&\multicolumn{4}{c}{Bank Loans} &Bond Market \\
\cmidrule[0.4pt](r{0.125em}){2-5}%
\cmidrule[0.4pt](r{0.125em}){6-6}% \\
& (1) & (2) & (3) & (4) & (5) \\
VARIABLES & a& b& c & d & e \\ \hline
& & & & & \\
\hline\hline
\end{tabular}
\end{threeparttable}
% \end{adjustbox}
\end{table}
\end{document}