Generalxypic yytree cannot connect node 11

LaTeX specific issues not fitting into one of the other forums of this category.
Post Reply
Linguist
Posts: 43
Joined: Mon Nov 07, 2011 12:07 pm

xypic yytree cannot connect node 11

Post by Linguist »

Hi All,

I am trying to typeset a simple "directory tree" using the xytree package. When I attempt to connect to node 11, no connection is drawn and all subsequent connections (e.g. to node 12) also do not display.

MWE:

Code: Select all

\documentclass{minimal}

\usepackage{xytree}

\begin{document}

\yytree{
\yynode[11,12]{parent} \\
& \yynode{child node 1} \\
& \yynode{child node 2} \\
& \yynode{child node 3} \\
& \yynode{child node 4} \\
& \yynode{child node 5} \\
& \yynode{child node 6} \\
& \yynode{child node 7} \\
& \yynode{child node 8} \\
& \yynode{child node 9} \\
& \yynode{child node 10} \\
& \yynode{child node 11} \\
& \yynode{child node 12} \\
}

\end{document}
I'm aware that there are other packages I could use for a similar function (e.g. dirtree) but I would like to use xytree for a variety of reasons (basically, it displays most nicely and is simple to use).

Any help would be appreciated.

Recommended reading 2024:

LaTeXguide.org • LaTeX-Cookbook.net • TikZ.org

NEW: TikZ book now 40% off at Amazon.com for a short time.

And: Currently, Packt sells ebooks for $4.99 each if you buy 5 of their over 1000 ebooks. If you choose only a single one, $9.99. How about combining 3 LaTeX books with Python, gnuplot, mathplotlib, Matlab, ChatGPT or other AI books? Epub and PDF. Bundle (3 books, add more for higher discount): https://packt.link/MDH5p

rais
Posts: 419
Joined: Sun Nov 16, 2014 8:51 pm

xypic yytree cannot connect node 11

Post by rais »

Hi,
you could try to put the 11 into braces, like

Code: Select all

\yynode[{11},12]{parent} \\
and notify the xytree package maintainer about this, please.

KR
Rainer
Linguist
Posts: 43
Joined: Mon Nov 07, 2011 12:07 pm

xypic yytree cannot connect node 11

Post by Linguist »

Thanks, this solution works.

For future readers I'll note that this problem happens with all multiples of 11 (e.g. 22, 33, 44)
Post Reply