Graphics, Figures & TablesTwo Words in four Columns

Information and discussion about graphics, figures & tables in LaTeX documents.
Post Reply
hvn
Posts: 13
Joined: Thu Feb 03, 2011 9:40 pm

Two Words in four Columns

Post by hvn »

Hi,

I'm trying to create a table with one row divided into two equal cells, each of which is on top of two cells:

Code: Select all

\begin{tabular}{|c|c|c|c|}
\hline
\multicolumn{4}{|c|c|}{NON & YES}\\
\hline
However, I get the error "Missing } inserted" for the \multicolumn line. Is it possible what I want to do, or am I doing it wrong?

Thank you.

Recommended reading 2024:

LaTeXguide.org • LaTeX-Cookbook.net • TikZ.org

NEW: TikZ book now 40% off at Amazon.com for a short time.

frabjous
Posts: 2064
Joined: Fri Mar 06, 2009 12:20 am

Two Words in four Columns

Post by frabjous »

You want:

Code: Select all

\begin{tabular}{|c|c|c|c|}
\hline
\multicolumn{2}{|c|}{NON} & \multicolumn{2}{c|}{YES}\\
\hline
hvn
Posts: 13
Joined: Thu Feb 03, 2011 9:40 pm

Re: Two Words in four Columns

Post by hvn »

Thank you very much. That works!
Post Reply