# Drawing multiple box plots from a file

I've got data in the following format

n lw lq m uq uw
50 200 209 237 327 569
100 376 379 386 390 391
150 ...
...


Where lw = lower whisker, lq = lower quartile, etc.

I want to plot each box against n on the x axis and end up with a figure that looks something like this:

(source: togaware.com)

I've been trying to modify an existing graph that was plotting the non-boxed data, but I can't find a way to configure it that doesn't result in LaTeX failing to compile.

\pgfplotstableread{code/tree/results.dat}\loadedtable

\begin{figure}
\begin{tikzpicture}
\begin{axis}[
axis lines=middle,
xlabel near ticks,
ylabel near ticks,
xlabel={Size of Tree $n$},
ylabel={Time $\mu$s},
width=11cm,
height=10cm
]

• Welcome to TeX.SX!! It is better to post a full minimal working example. For example, A LaTeX MWE should start with a \documentclass command, have a minimal preamble and then \begin{document}...\end{document}. Unless the problem is a compilation error, the code should compile and be as small as possible to demonstrate your problem. This makes it much easier for people to help you --- and much more likely that they will! – Andrew May 6 '16 at 14:45