I have a rather wide table (13 columns) that I convert from Excel to LaTex. I use resizebox to make the table fit within the page. But the numbers in the table are minuscule. Any recommendations on how to change that? I don't want the caption text to change and the table should also fit into the page.
Here is my basic code:
\usepackage{pdflscape}
\usepackage[left=1.0in, right=1.0in, top=1.0in, bottom=1.0in]{geometry}
\usepackage[table]{xcolor}
\usepackage{layout}
\usepackage{footnote}
\usepackage{epstopdf}
\usepackage{lscape}
\usepackage{rotating}
\usepackage{subfigure}
\usepackage{graphicx}
\usepackage{amsmath}
\usepackage{amsthm}
\usepackage{setspace}
\usepackage{amsfonts}
\usepackage{amssymb}
\usepackage{longtable}
\usepackage{color}
\usepackage{natbib}
\usepackage{setspace}
\usepackage{multirow}
\usepackage{caption}
\usepackage{hyperref}
\usepackage{booktabs}
\usepackage{float}
\usepackage{adjustbox}
\usepackage[normalem]{ulem}
\usepackage{xr}
\usepackage{longtable}
%*****The commands below define new column types suited for variable description************
\usepackage{array}
\newcolumntype{L}[1]{>{\raggedright\let\newline\\\arraybackslash\hspace{0pt}}m{#1}}
\newcolumntype{C}[1]{>{\centering\let\newline\\\arraybackslash\hspace{0pt}}m{#1}}
\begin{document}
\begin{landscape}
\begin{center}
\begin{scriptsize}
\begin{table}[htb]
\centering
\captionsetup{singlelinecheck=off}
\caption[.]{\textbf{This is a test table}\newline
\footnotesize{ This table reports estimates from the following panel regression model:
\begin{equation*}
\begin{split}
ABCD\textsuperscript{xyz}Firm_{ijt}=\alpha_0+\beta_{1}\times FirmSize_{ijt} +\beta_{2} \times FirmAge_{it}+\beta_{3} \times Profit_{jt} \times FirmSize_{j} \\
+ \beta_{4} \times FirmAge_{ijt} \times Profits_{j} +
\beta_{5} \times Market_{ijt} \times Profits_{j} +
\phi_{j}+\gamma_{t}+\varepsilon_{ijt}
\end{split}
\end{equation*}
A big caption (9 lines of text) goes here describing all the variables
}
}
\resizebox{1\textwidth}{!}{
\begin{tabular}{lcccc|cccc|cccc|}
\toprule
\multicolumn{7}{l}{\textbf{Panel A: Some text here}} \\
\midrule
& 1 & 2 & 3 & 4 & 5 & 6 & 7 & 8 & 9 & 10 & 11 & 12 \\
\midrule
& ABCD\textsuperscript{xyz}Firm & ABCD\textsuperscript{xyz}Firm & ABCD\textsuperscript{xyz}Firm & ABCD\textsuperscript{xyz}Firm & ABCD\textsuperscript{xyz}Firm & ABCD\textsuperscript{xyz}Firm & ABCD\textsuperscript{xyz}Firm & ABCD\textsuperscript{xyz}Firm & ABCD\textsuperscript{xyz}Firm & ABCD\textsuperscript{xyz}Firm & ABCD\textsuperscript{xyz}Firm & ABCD\textsuperscript{xyz}Firm \\
\midrule
& ABCD & ABCD & ABCD & ABCD & EFGH & EFGH & EFGH & EFGH & PQRS & PQRS & PQRS & PQRS \\
\midrule
FirmSize & 0.027*** & 0.023*** & 0.023*** & 0.023*** & 0.008*** & 0.033*** & 0.043*** & 0.063*** & 0.025*** & 0.043*** & 0.053*** & 0.063*** \\
& (0.003) & (0.002) & (0.002) & (0.002) & (0.002) & (0.002) & (0.002) & (0.002) & (0.002) & (0.002) & (0.002) & (0.002) \\
FirmAge & -0.096*** & -0.097*** & -0.097*** & -0.098*** & -0.097*** & -0.088*** & -0.088*** & -0.088*** & -0.097*** & -0.097*** & -0.088*** & -0.068*** \\
& (0.005) & (0.005) & (0.005) & (0.005) & (0.005) & (0.005) & (0.005) & (0.005) & (0.005) & (0.005) & (0.005) & (0.005) \\
Mkt & 0.043 & 0.053 & 0.166** & 0.035 & 0.027 & 0.043 & 0.056 & 0.012 & 0.032 & 0.044 & 0.118 & 0.020 \\
& (0.088) & (0.088) & (0.228) & (0.088) & (0.090) & (0.089) & (0.092) & (0.091) & (0.089) & (0.089) & (0.215) & (0.090) \\
Share & 0.114 & 0.011 & 0.011 & 0.999 & 0.127 & 0.035 & 0.044 & 0.056 & 0.312 & 0.039 & 0.056 & 0.679 \\
& (0.124) & (0.119) & (0.119) & (0.308) & (0.121) & (0.119) & (0.119) & (0.119) & (0.120) & (0.119) & (0.120) & (0.285) \\
Profits & 0.3*** & 0.276*** & 0.264*** & 0.264*** & 0.267*** & 0.254*** & 0.265*** & 0.265*** & 0.268*** & 0.269*** & 0.266*** & 0.265*** \\
& (0.026) & (0.026) & (0.026) & (0.026) & (0.026) & (0.028) & (0.026) & (0.026) & (0.026) & (0.026) & (0.026) & (0.026) \\
FirmSize x Profits & -0.011*** & & & & 0.010*** & & & & 0.013*** & & & \\
& (0.003) & & & & (0.003) & & & & (0.004) & & & \\
FirmAge x Profits & & -0.042** & & & & 0.049 & & & & 0.038 & & \\
& & (0.018) & & & & (0.02) & & & & (0.023) & & \\
Mkt x Profits & & & -0.668*** & & & & -0.006 & & & & 0.327 & \\
& & & (0.246) & & & & (0.203) & & & & (0.305) & \\
Share x Profits & & & & -0.560 & & & & 0.123 & & & & 0.327 \\
& & & & (0.355) & & & & (0.435) & & & & (0.500) \\
N & 60000 & 60000 & 60000 & 60000 & 60000 & 60000 & 60000 & 60000 & 60000 & 60000 & 60000 & 60000 \\
adj. R-sq & 0.067 & 0.076 & 0.072 & 0.079 & 0.067 & 0.075 & 0.074 & 0.064 & 0.079 & 0.075 & 0.072 & 0.074 \\
\cmidrule(lr){2-5} \cmidrule(lr){6-9} \cmidrule(l){10-13}
Fixed Effects
& \multicolumn{4}{c}{Industry, Year}
& \multicolumn{4}{c}{Industry, Year}
& \multicolumn{4}{c}{Industry, Year} \\
\bottomrule
\end{tabular}%
}
\end{table}
\end{scriptsize}
hyperref
package should generally and with a few exceptions be loaded as the last package. Regarding your question: Usingresizebox
in order to make a table fit onto a page is not recommended, as it leads to inconsistent and in some cases illegibly small font sizes. The contents of the table seem to be placeholders. Could you please also add some information on how wide the actual column headers and contents are?booktabs
's horizontal lines are incompatible with vertical lines. You might want to consider removing the latter. Also, all the\multicolumn{1}
command seem to be unnecessary and can be removed.