I've done a table but it is way too big in order to be displayed on one page. Does someone know a way how to change the table so that it fits? Thanks in advance.
\documentclass[12pt]{article}
\usepackage{geometry}
\geometry{a4paper}
\usepackage{eurosym}
\usepackage{graphicx}
\usepackage{float}
\usepackage{wrapfig}
\usepackage{lipsum}
\usepackage[applemac]{inputenc}
\usepackage{booktabs}
\usepackage{tabularx}
\usepackage{pdflscape}
\usepackage{afterpage}
\usepackage{fancyref}
\renewcommand{\arraystretch}{1.5}
\linespread{1.2}
\begin{document}
\begin{table}[h!]
\centering
\begin{tabular}{||c | c | c||}
\hline
Non-agricultural & Agricultural & Service \\ [0.5ex]
\hline\hline
Fishing & Paddy rice & Electricity \\
Coal & Wheat & Gas \\
Oil & Cereal grains & Water \\
Gas & Vegetables,fruits,nuts & Construction \\
Minerals & Oil seeds & Trade \\
Wool & Sugar cane/beet & Transport \\
Textiles & Plant-based fibers & Sea transport \\
Waring apparel & Crops nec & Air transport \\
Leather products & Cattle,sheep,goats,horse & Communication \\
Forestry & Animal products & Financial services nec \\
Wood products & Raw milk & Insurance \\
Paper products & Meat:cattle,sheep,goats,horse & Business services nec \\
Petroleum,coal products & Meat products nec & Recreation and other services \\
Chemical,rubber,plastic & Vegetable oils and fats & PubAdmin/Defence/Health/Educat \\
Mineral products nec & Dairy products & Dwellings \\
Ferrous metals & Processed rice & \\
Metals nec & Sugar & \\
Metal products & Food products & \\
Motor vehicles/parts& Beverages and tobacco & \\
Transport equipment nec & & \\
Electronic equipment& & \\
Machinery and equipment nec & & \\
Manufactures nec & & \\ [1ex]
\hline
\end{tabular}
\caption{Sector aggregation}
\label{table:1}
\end{table}
\end{document}
Best Answer
Your table will fit easily on one page -- and within the width of the text block -- if you (a) let the contents of the columns "wrap" as needed and (b) dispense with the
\renewcommand{\arraystretch}{1.5}
instruction. (Actually, the table will fit even if\arraystretch
is redefined, but the result doesn't look as good, IMNSHO.)Specifically, I suggest you employ a
tabularx
environment instead of thetabular
environment and make use of the line-drawing macros of thebooktabs
package (which is already being loaded in your example). Give serious thought to omitting all vertical lines in the table: trust me, they won't be missed, and the table will have a much more open look.A useful trick: Use the
\slash
macro instead of the hard-coded/
symbol to allow linebreaks, if needed, after the slash characters.