Graphics, Figures & Tablestable is not aligned

Information and discussion about graphics, figures & tables in LaTeX documents.
Post Reply
me_here_me
Posts: 46
Joined: Mon Feb 05, 2007 5:19 pm

table is not aligned

Post by me_here_me »

The problem is solved, thanks

I tried to make a table using the following code but the table is not aligned.

Code: Select all

\begin{table*}[!ht]
  \centering
  \scriptsize
  \caption{Table caption}\label{table:tasks}
  \begin{tabular}{*{11}{c}}
    & Task 1 & Task 1 & Task 2 & Task 2 & Task 3 & Task 3 & Task 4 & Task 4 & Task 5 & Task 5 \\
    & result achieved & time & result achieved & time & result achieved & time & result achieved & time & result achieved & time \\ \hline
    User 1 & do not know & 0.5 & correct & 4 & correct & 2 & correct & 7 & correct & 3 \\
    User 2 & correct & 6 & correct & 3 & correct & 1 & not applicable & --- & correct & 5 \\
    User 3 & correct & 5 & correct & 3 & correct & 1 & do not know & 4 & correct & 4 \\
    User 4 & correct & 6 & correct & 2 & correct & 0.5 & correct & 9 & correct & 4 \\ \hline
    Mean time & --- & 5.6 & --- & 3 & --- & 1.1 & --- & 8 & --- & 4 \\
  \end{tabular}
\end{table*}

Recommended reading 2024:

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

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

And: Currently, Packt sells ebooks for $4.99 each if you buy 5 of their over 1000 ebooks. If you choose only a single one, $9.99. How about combining 3 LaTeX books with Python, gnuplot, mathplotlib, Matlab, ChatGPT or other AI books? Epub and PDF. Bundle (3 books, add more for higher discount): https://packt.link/MDH5p

localghost
Site Moderator
Posts: 9202
Joined: Fri Feb 02, 2007 12:06 pm

Re: table is not aligned

Post by localghost »

I think others are also interested in the solution. Otherwise this topic is wasted.


Best regards
Thorsten¹
Post Reply