Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

I'm not an expert in LaTeX, and just want to ask. How can we build the following table in LaTeX?

enter image description here

Thanks.

share|improve this question
3  
Does the linked question help? If not, please show us what you've tried thus far by including a minimal working example (MWE). From there it would be far easier to advise and help. –  Werner May 17 at 17:30
add comment

1 Answer 1

Some pointers:

  • Since most the cells should be in math mode rather than text mode, use an array rather than a tabular environment.

  • Use text-mode bold italics, when needed, because the letters and numbers should be spaced tightly. Don't use math-mode bold italics in this setting even if that font combination is available.

  • For frequently occurring instructions (to set material in text-mode bold italics, say), create shortcut macros as needed.

  • Use \multirow (from the multirow package) to place a cell's contents halfway across two rows.

  • Use commands such as \midrule (from the booktabs package) to get well-spaced horizontal lines. (If for some reason you don't want to create well-spaced lines, use \hline instead...) Try hard not to use any vertical lines.

  • The example below loads the newtxtext and newtxmath font packages because the screen shot you provided appears to use the Times (New) Roman font family. If you're content using another font, don't load these two packages.

enter image description here

\documentclass{article}
\usepackage{booktabs} % for \midrule macro
\usepackage{multirow} % for \multirow macro
\usepackage{newtxtext,newtxmath} % Times Roman fonts
\newcommand\xx[1]{\textbf{\textit{#1}}}% shortcut macro
\begin{document}
$\begin{array}{*{4}{c}}
\xx{A} & \xx{I1} & \xx{I2} & \xx{I3} \\
\midrule
\multirow{2}{*}{$\xx{s}$} & -0.056 & -0.117 & 0.000  \\
                          & \pm0.09& \pm0.12& \pm0.00\\[1ex]
\multirow{2}{*}{$\xx{c}$} &    1066 &    1255 &    1099\\
                          & \pm1087 & \pm1189 & \pm1113\\
\midrule
\xx{o} & \xx{2} & \xx{2} & \xx{4}\\
\end{array}$
\end{document}
share|improve this answer
1  
.. and the vertical rule ;-) ? –  jfbu May 17 at 20:25
1  
@jfbu - I deliberately did not produce a vertical rule. :-) If the OP really wants it, he/she should use \hline instead of \midrule... –  Mico May 17 at 20:32
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.