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 am using nested table environments in the following snippet:

\begin{document}
\noindent
\begin{tabularx}{\textwidth}{rX lX}

  COURSEWORK & Machine Learning, Probabilitistic Learning, Probabilistic Graphical Models, Intermediate Statistics A \& B, Statistical Methodology I \& II, Statistical Computing, Information Retreival, Principles of Data Management, Data Structures, Computer Architecture\\
 \\*
  COURSEWORK & \begin{tabular}{ l l l }
   Machine Learning & Probabilistic Learning & Probabilistic Graphical Models \\
   Intermediate Statistics & Statistical Computing & Statistical Methods \\
   Principles of Data  & Data Structures & Computer Architecture \\
  \end{tabular}\\

\end{tabularx}

which produces following document:

enter image description here

Now, there are three issues with this rendering:

  1. The tabular listing of courses seems to have extra indentation (note the entries are already left justified) &
  2. The section title 'COURSEWORK' for the tabular listing appears in front of middle row, I would like it to start from the top of the tabular listing. I tried using \multirow but it does not take the section title above the middle row.

Please suggest how these can be achieved.

share|improve this question

1 Answer 1

up vote 5 down vote accepted

Remove the \tabcolsep length at the beginning and at the end of the tabulars using @{}; the alignment issue can be corrected using t for the optional argument of tabular:

\documentclass{article}
\usepackage{tabularx}
\begin{document}
\noindent
\begin{tabularx}{\textwidth}{@{} r X l X @{}}
  COURSEWORK & Machine Learning, Probabilitistic Learning, Probabilistic Graphical Models, Intermediate Statistics A \& B, Statistical Methodology I \& II, Statistical Computing, Information Retreival, Principles of Data Management, Data Structures, Computer Architecture\\
 \\*
  COURSEWORK & \begin{tabular}[t]{@{} l l l @{} }
   Machine Learning & Probabilistic Learning & Probabilistic Graphical Models \\
   Intermediate Statistics & Statistical Computing & Statistical Methods \\
   Principles of Data  & Data Structures & Computer Architecture \\
  \end{tabular}\\
\end{tabularx}

\end{document}

enter image description here

share|improve this answer
    
Thanks! Works perfectly! –  abhinavkulkarni Oct 7 '12 at 6:41

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.