# creating complex table [duplicate]

Can anyone help creating this table,I can't figure it out.

I tried this code but got some errors:

\begin{tabular}{|c|c|c|c|c|}
\hline
something & \multicolumn{4}{ c| }{something} \\  \cline{2-5}
& $t_{1}$‎ & $t_{2}$‎ & ... & $t_{n}$‎ \\  \hline
\multicolumn{1}{ |c|  }{\multirow{‎d1} & 1 & 2 & 3 & 4 $\\ \hline \end{tabular}  Thanks in advance. ## marked as duplicate by Arun Debray, user13907, Romain Picot, Svend Tveskæg, percusseJan 20 '16 at 22:31 This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question. • Have you attempted to do this yourself? If so please post any code you have so far. – Null Jan 20 '16 at 19:26 ## 1 Answer Your table is rather simple :-). I will assume, that the width of column is expected to be self adjusted to the widest content and that it should be centered. For cell which occupy tho rows in one column you can define by help of package multirow: \documentclass{article} \usepackage{multirow} \begin{document} \begin{tabular}{|*{4}{c|}} \hline \begin{multicolumn{4}{c}{something} & \multirow{2}*{something} \\ \cline{1-4} A & B & C & D & \\ \hline 1 & 2 & 3 & 4 &$d_1$\\ \hline & & & &$d_2\$     \\
\hline
\end{tabular}

\end{document}


For meaning of table code please read some basic literature about LaTeX. For example "Not so short introduction to LaTeX ...` which is part of all LaTeX distribution.