How do I center this wide table in LaTeX?
use \resizebox
:
\documentclass[a4paper,12pt]{report}
\usepackage{graphicx}
\usepackage{booktabs,caption,fixltx2e}
\usepackage{subfig}
\captionsetup{belowskip=12pt,aboveskip=4pt}
\begin{document}
\begin{table}[htb!]
\resizebox{\linewidth}{!}{\def\arraystretch{1.5}%
\begin{tabular}{lrrrcrrrcrrrcrrr}
\hline\hline
\multicolumn{1}{l}{\bfseries Trans}&\multicolumn{3}{c}{\bfseries 50}&\multicolumn{1}{c}{\bfseries }&\multicolumn{3}{c}{\bfseries 100}&\multicolumn{1}{c}{\bfseries }&\multicolumn{3}{c}{\bfseries 200}&\multicolumn{1}{c}{\bfseries }&\multicolumn{3}{c}{\bfseries 400}\tabularnewline
\cline{2-4} \cline{6-8} \cline{10-12} \cline{14-16}
\multicolumn{1}{l}{}&\multicolumn{1}{c}{b0}&\multicolumn{1}{c}{b1}&\multicolumn{1}{c}{b2}&\multicolumn{1}{c}{}&\multicolumn{1}{c}{b0}&\multicolumn{1}{c}{b1}&\multicolumn{1}{c}{b2}&\multicolumn{1}{c}{}&\multicolumn{1}{c}{b0}&\multicolumn{1}{c}{b1}&\multicolumn{1}{c}{b2}&\multicolumn{1}{c}{}&\multicolumn{1}{c}{b0}&\multicolumn{1}{c}{b1}&\multicolumn{1}{c}{b2}\tabularnewline
\hline
\bfseries No&&&&&&&&&&&&&&&\tabularnewline
~~fw&$0.83$&$$&$-0.0017$&&$0.90$&$ 0.01018$&$-1.2e-03$&&$0.94$&$$&$$&&$0.97$&$$&$-0.00042$\tabularnewline
~~bw&$0.88$&$$&$$&&$0.94$&$$&$$&&$$&$$&$$&&$0.98$&$$&$$\tabularnewline
~~sp&$0.81$&$0.0031$&$$&&$$&$$&$$&&$$&$$&$$&&$$&$$&$$\tabularnewline
\hline
\bfseries Blom&&&&&&&&&&&&&&&\tabularnewline
~~fw&$1.00$&$$&$$&&$1.00$&$-0.00024$&$ 2.3e-05$&&$1.00$&$$&$$&&$1.00$&$$&$$\tabularnewline
~~bw&$0.90$&$$&$-0.0667$&&$0.95$&$$&$-9.1e-02$&&$0.97$&$$&$$&&$0.99$&$$&$$\tabularnewline
~~sp&$0.81$&$$&$$&&$0.90$&$-0.07838$&$-9.6e-02$&&$0.95$&$$&$$&&$0.98$&$$&$$\tabularnewline
\hline
\bfseries Log&&&&&&&&&&&&&&&\tabularnewline
~~fw&$0.86$&$$&$$&&$0.92$&$$&$$&&$$&$$&$$&&$$&$$&$$\tabularnewline
~~bw&$$&$$&$$&&$$&$$&$-9.4e-03$&&$$&$$&$$&&$$&$$&$$\tabularnewline
~~sp&$$&$$&$$&&$$&$$&$$&&$$&$$&$$&&$$&$$&$$\tabularnewline
\hline
\end{tabular}}
\end{table}
\end{document}
and if you want it wider than the linewidth but centered use:
[...]
\begin{table}[htb!]
\makebox[\textwidth]{\resizebox{1.1\linewidth}{!}{\def\arraystretch{1.5}%
\begin{tabular}{lrrrcrrrcrrrcrrr}
[...]
\end{tabular}}}
the first one is 1.1\textwidth
and the second \textwidth
:
You're not using properly booktabs
; you don't need to add dummy columns, for instance. Then, with siunitx
you can ensure uniform appearance of the data.
Finally, adjustbox
makes it easy to rescale the table to fit.
\documentclass[a4paper,12pt]{report}
\usepackage{booktabs,siunitx}
\usepackage{adjustbox}
\begin{document}
\begin{table}[!htp]
\centering
\begin{adjustbox}{max width=\columnwidth}
\begin{tabular}{@{}
l
S[table-format=1.2]
S[table-format=1.4]
S[table-format=-1.4]
%
S[table-format=1.2]
S[table-format=-1.5]
S[table-format=-1.1e-1]
%
S[table-format=1.2]
S[table-format=1.2]% actually empty
S[table-format=1.2]% actually empty
%
S[table-format=1.2]
S[table-format=1.2]% actually empty
S[table-format=-1.5]
@{}}
\toprule
\multicolumn{1}{l}{\bfseries Trans}&
\multicolumn{3}{c}{\bfseries 50}&
\multicolumn{3}{c}{\bfseries 100}&
\multicolumn{3}{c}{\bfseries 200}&
\multicolumn{3}{c}{\bfseries 400}\\
\cmidrule(lr){2-4} \cmidrule(lr){5-7} \cmidrule(lr){8-10} \cmidrule(l){11-13}
& {b0} & {b1} & {b2} & {b0} & {b1} & {b2} & {b0} & {b1} & {b2} & {b0} & {b1} & {b2} \\
\midrule
{\bfseries No}\\
fw & 0.83 & & -0.0017 & 0.90 & 0.01018 & -1.2e-03 & 0.94 & & & 0.97 & & -0.00042 \\
bw & 0.88 & & & 0.94 & & & & 0.98 & & \\
sp & 0.81 & 0.0031 & & & & & & & & \\
\midrule
{\bfseries Blom}\\
fw & 1.00 & & & 1.00 &-0.00024 & 2.3e-05 & 1.00 & & & 1.00 & & \\
bw & 0.90 & & -0.0667 & 0.95 & &-9.1e-02 & 0.97 & & & 0.99 & & \\
sp & 0.81 & & & 0.90 &-0.07838 &-9.6e-02 & 0.95 & & & 0.98 & & \\
\midrule
{\bfseries Log}\\
fw & 0.86 & & & 0.92 & & & & & & & & \\
bw & & & & & &-9.4e-03 & & & & & & \\
sp & & & & & & & & & & & & \\
\bottomrule
\end{tabular}
\end{adjustbox}
\end{table}
\end{document}
\hspace*{-\textwidth}\begin{tabular}
...
\end{tabular}\hspace*{-\textwidth}
will hide the width so it centers in the text block and bleeds into the margin/