[Tex/LaTex] how to make three row with multirow package

multirowtables

enter image description hereI have a code that prints a table with 2 rows. I want to keep format of it and change 2 rows into 3.

\documentclass[conference]{IEEEtran}

\usepackage{pgfplots}
\usepackage{siunitx}
\usepackage{multirow}
\begin{document}

\begin{table}[h]
\caption{Family data set results}
\label{tbl::Fam}
\centering
\begin{tabular}{|l|l|c|c|c!{\vrule width 2pt}l|l|c|c|c|}
%\noalign{\hrule height 2pt}
\hline
\textbf{Column}&\textbf{Algorithm}&\textbf{min}&\textbf{max}&\textbf{std}l&\textbf{Column}&\textbf{Algorithm}&\textbf{min}&\textbf{max}&\textbf{std}\\\hline
\multirow{2}{*}{age}&Original&9&2.8&100&\multirow{2}{*}{employer\_type}&Original&13&2&10\\ \cline{2-5} \cline{7-10}&PrivBayes&2&95&96&&PrivBayes&2&100&100\\\hline
\multirow{2}{*}{education\_level}&Original&7&2&98&\multirow{2}{*}{marital\_status}&Original&10&2&100\\ \cline{2-5} \cline{7-10}&PrivBayes&2&6&96&&PrivBayes&2&6&100\\\hline
\hline %\noalign{\hrule height 2pt}
\end{tabular}
\end{table}

\end{document}

In this picture, I have 2 algorithms {Original, PrivBayes}. I want to change 2 algorithms into 3 algorithms with keeping the format of table.
Can you please help me to do it?

Best Answer

Your table appears to be considerably wider than the text block is. The easiest remedy would convert the table from a 10-column structure to a more-manageable (and easier on the readers' eyes) 5-column structure.

While you're at it, you may want to give the table a more "open" look, to invite the reader to actually look at and hopefully even absorb the information provided in the table. I suggest you (a) get rid of all vertical rules, (b) use fewer, but well-spaced, horizontal rules, (c) not use any bold fonts and (d) align the numbers in the three numeric columns on their (implicit) decimal markers.

Oh, and I wouldn't use any \multirow directives for the entries in the first column; they're simply not needed.

enter image description here

\documentclass[conference]{IEEEtran}

\usepackage{booktabs,siunitx}
\begin{document}

\begin{table}[h]
\caption{Family dataset results}
\label{tbl::Fam}
\centering
\begin{tabular}{@{} ll *{3}{S[table-format=3.0]} @{}}
\toprule
Column&Algorithm&{min}&{max}&{std.dev.}\\
\midrule
age&Original &9&28&100\\
   &PrivBayes&2&95&96\\
   &ThirdAlg &10&90&50\\
\addlinespace
education\_level&Original&7&28&98\\
                &PrivBayes&2&6&96\\
                &ThirdAlg &10&90&50\\
\addlinespace
employer\_type&Original&13&2&10\\
              &PrivBayes&2&100&100\\
              &ThirdAlg &10&90&50\\
\addlinespace
marital\_status&Original&10&20&100\\
               &PrivBayes&2&6&100\\
               &ThirdAlg &10&90&50\\
\bottomrule
\end{tabular}
\end{table}
\end{document}
Related Question