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 need a package to draw a Gantt chart in LaTeX, the primary criteria is just: ease of use. I am spending too much time learning "packages" here and there, this just needs to get a simple job done. I might be interested to know which ones are "better" for later reference, include them if you like, but for now... quick and dirty is golden.

share|improve this question
4  
I think you should have a look to the pgfgantt package. –  Claudio Fiandrino Jul 19 '12 at 9:01
    
Surely there is a package for that (there is always a package! :-)) but just in case you find it useful, I did a quick&dirty solution via tikz long time ago, when I was learning TikZ. I published it in a (now abandoned) wiki at jldiaz.wikidot.com/en-tikz-example:gantt –  JLDiaz Jul 19 '12 at 9:01
    
searching ctan returns versions using metapost, pstricks and pgf, as well as a latex contrib package rtsched; i've not used any of them (i'm just the guy who writes the catalogue). ... so @claudio -- there isn't a package, there are several ;-) –  wasteofspace Jul 19 '12 at 9:10

2 Answers 2

up vote 24 down vote accepted

Like Claudio, I suggest you to use the pgfGantt package, which I find quite simple, and whose documentation is quite clear.

Here is a MWE, with custom label, progress bar and relations:

\documentclass{article}
\usepackage{pgfgantt}

\begin{document}

\begin{figure}[ftbp]
\begin{center}

\begin{ganttchart}[y unit title=0.4cm,
y unit chart=0.5cm,
vgrid,hgrid, 
title label anchor/.style={below=-1.6ex},
title left shift=.05,
title right shift=-.05,
title height=1,
bar/.style={fill=gray!50},
incomplete/.style={fill=white},
progress label text={},
bar height=0.7,
group right shift=0,
group top shift=.6,
group height=.3,
group peaks={}{}{.2}]{24}
%labels
\gantttitle{Week}{24} \\
\gantttitle{Monday}{4} 
\gantttitle{Tuesday}{4} 
\gantttitle{Wednesday}{4} 
\gantttitle{Thursday}{4} 
\gantttitle{Friday}{4} 
\gantttitle{Saturday}{4} \\
%tasks
\ganttbar{first task}{1}{2} \\
\ganttbar{task 2}{3}{8} \\
\ganttbar{task 3}{9}{10} \\
\ganttbar{task 4}{11}{15} \\
\ganttbar[progress=33]{task 5}{20}{22} \\
\ganttbar{task 6}{18}{19} \\
\ganttbar{task 7}{16}{18} \\
\ganttbar[progress=0]{task 8}{21}{24}

%relations 
\ganttlink{elem0}{elem1} 
\ganttlink{elem0}{elem3} 
\ganttlink{elem1}{elem2} 
\ganttlink{elem3}{elem4} 
\ganttlink{elem1}{elem5} 
\ganttlink{elem3}{elem5} 
\ganttlink{elem2}{elem6} 
\ganttlink{elem3}{elem6} 
\ganttlink{elem5}{elem7} 
\end{ganttchart}
\end{center}
\caption{Gantt Chart}
\end{figure}

\end{document}

enter image description here

share|improve this answer
2  
This version yields several errors with me, I think because you're not using the current version (pgfgantt v4.0) which - as the documentation says - is not fully backwards compatible. The example from the documentation works fine (section 2.1 on page 3). –  Joker Aug 8 '13 at 13:59
    
@Alan Munn want to reproduce the code for my PhD Thesis Time Schedule. tex.stackexchange.com/questions/185865/… –  SKKhan Jun 21 at 6:36

I use the gantt package. It is simple enough in my experience, but then again, I am not doing anything too fancy like the multiple dependencies shown in the previous answer.

share|improve this answer
1  
Welcome to TeX.SE! You can have a look at our starter guide to familiarize yourself further with our format. I don't find a gantt package on CTAN. If you mean the pgfgantt package, you should differentiate your answer from corentin's answer showing usage of the package. –  Paul Gessler Jul 2 at 13:15

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.