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.

How to create this table in latex.

Name    A   B   C         D    Name A   B    C      D


A   0   997 4.167   0.613   B   0   783 1.636   0.150
    0.04    1164    4.139   0.676       0.04    959 1.710   0.168
    0.08    1332    4.111   0.744       0.08    1135    1.783   0.187
    0.12    1499    4.083   0.817       0.12    1311    1.857   0.208
    0.16    1666    4.055   0.895       0.16    1487    1.930   0.231
    0.2 1834    4.028   0.980       0.2 1662    2.003   0.256
C   0   997 4.167   0.613   D   0   783 1.636   0.150
    0.04    1153    4.138   0.660       0.04    948 1.708   0.167
    0.08    1310    4.108   0.710       0.08    1113    1.780   0.184
    0.12    1466    4.079   0.763       0.12    1278    1.852   0.204
    0.16    1623    4.050   0.818       0.16    1443    1.924   0.224
    0.2 1779    4.020   0.877       0.2 1608    1.996   0.247
E   0   997 4.167   0.613   F   0   783 1.636   0.150
    0.04    1210    4.136   0.688       0.04    1004    1.706   0.169
    0.08    1423    4.104   0.769       0.08    1226    1.776   0.189
    0.12    1636    4.073   0.857       0.12    1447    1.846   0.211
    0.16    1849    4.042   0.953       0.16    1669    1.916   0.235
    0.2 2062    4.011   1.059       0.2 1890    1.986   0.262
share|improve this question

closed as too localized by doncherry, lockstep, Thorsten, Stephen, diabonas Oct 31 '12 at 9:28

This question is unlikely to help any future visitors; it is only relevant to a small geographic area, a specific moment in time, or an extraordinarily narrow situation that is not generally applicable to the worldwide audience of the internet. For help making this question more broadly applicable, visit the help center.If this question can be reworded to fit the rules in the help center, please edit the question.

5  
Welcome to TeX.sx! On this site, a question should typically revolve around an abstract issue (e.g. "How do I get a double horizontal line in a table?") rather than a concrete application (e.g. "How do I make this table?"). Questions that look like "Please do this complicated thing for me" tend to get closed because they are "too localized". Please try to make your question clear and simple by giving a minimal working example (MWE): you'll stand a greater chance of getting help. –  jens_bo Oct 25 '12 at 3:09
    
Usually, we don't put a greeting or a "thank you" in our posts. While this might seem strange at first, it is not a sign of lack of politeness, but rather part of our trying to keep everything very concise. Upvoting is the preferred way here to say "thank you" to users who helped you. –  Guido Oct 25 '12 at 4:19

1 Answer 1

up vote 6 down vote accepted

I suggest using the booktabs package for its well-styled horizontal rules and the siunitx package for its ability to align columns of numbers on their decimal points. I'd also insert a bit of vertical whitespace between the A/B, C/D, and E/F groups of numbers. Finally, I'd advise against using any vertical rules in the table.

enter image description here

\documentclass{article}      
\usepackage{booktabs,siunitx}
\sisetup{table-format=1.3} % default numerical column spec
\begin{document}

\begin{table}
\centering
\begin{tabular}{@{}*{2}{l S[table-format=1.2] S[table-format=4.0] SS} @{}}
\toprule   % center non-numerical info (A, B, ...) by placing them in braces
Name & {A} & {B} & {C} & {D} & Name & {A} & {B} & {C} & {D} \\
\cmidrule(r){1-5}  \cmidrule(l){6-10} % leave gap between the two rules
A & 0    &  997 & 4.167 & 0.613 & B    & 0    &  783 & 1.636 & 0.150\\
  & 0.04 & 1164 & 4.139 & 0.676 &      & 0.04 &  959 & 1.710 & 0.168\\
  & 0.08 & 1332 & 4.111 & 0.744 &      & 0.08 & 1135 & 1.783 & 0.187\\
  & 0.12 & 1499 & 4.083 & 0.817 &      & 0.12 & 1311 & 1.857 & 0.208\\
  & 0.16 & 1666 & 4.055 & 0.895 &      & 0.16 & 1487 & 1.930 & 0.231\\
  & 0.2  & 1834 & 4.028 & 0.980 &      & 0.2  & 1662 & 2.003 & 0.256\\[1ex]
C & 0    &  997 & 4.167 & 0.613 & D    & 0    &  783 & 1.636 & 0.150\\
  & 0.04 & 1153 & 4.138 & 0.660 &      & 0.04 &  948 & 1.708 & 0.167\\
  & 0.08 & 1310 & 4.108 & 0.710 &      & 0.08 & 1113 & 1.780 & 0.184\\
  & 0.12 & 1466 & 4.079 & 0.763 &      & 0.12 & 1278 & 1.852 & 0.204\\
  & 0.16 & 1623 & 4.050 & 0.818 &      & 0.16 & 1443 & 1.924 & 0.224\\
  & 0.2  & 1779 & 4.020 & 0.877 &      & 0.2  & 1608 & 1.996 & 0.247\\[1ex]
E & 0    &  997 & 4.167 & 0.613 & F    & 0    &  783 & 1.636 & 0.150\\
  & 0.04 & 1210 & 4.136 & 0.688 &      & 0.04 & 1004 & 1.706 & 0.169\\
  & 0.08 & 1423 & 4.104 & 0.769 &      & 0.08 & 1226 & 1.776 & 0.189\\
  & 0.12 & 1636 & 4.073 & 0.857 &      & 0.12 & 1447 & 1.846 & 0.211\\
  & 0.16 & 1849 & 4.042 & 0.953 &      & 0.16 & 1669 & 1.916 & 0.235\\
  & 0.2  & 2062 & 4.011 & 1.059 &      & 0.2  & 1890 & 1.986 & 0.262\\
\bottomrule
\end{tabular}
\end{table}
\end{document}
share|improve this answer
2  
I don't think this question should be answered the way it is right now ... meta.tex.stackexchange.com/questions/2414/… –  doncherry Oct 25 '12 at 7:26

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