{forest} is about trees in {diagrams} created with the forest package. It is built upon {tikz-pgf}.

learn more… | top users | synonyms

6
votes
1answer
38 views

Horizontally aligned terminal nodes in trees with nice empty nodes using forest

When horizontally aligning terminal nodes in trees using the package forest, I run into problems when I try to use the 'nice empty nodes' option, which makes sure that unlabeled nodes connect (this ...
1
vote
1answer
64 views

drawing game trees: forest or qtree? [duplicate]

I hope this question actually is in order since it does not seem to have a "correct" answer: I am about to get into drawing game-theoretic trees and while I am familiar with LaTeX in general, I am ...
1
vote
1answer
65 views

Drawing condensed version of complex dependency diagrams

I got a cool solution to my question drawing complex dependency diagrams with tikz / forest and want to reuse this style for drawing a condensed version of the diagram that is supposed to look like ...
4
votes
1answer
48 views

Odd incompatibility between multi-line forest nodes and tabular

The following MWE compiles just fine: \documentclass{article} \usepackage{forest} \begin{document} %\begin{tabular}{c} \begin{forest} [x\\y, align=center [z] ] \end{forest} ...
3
votes
1answer
39 views

What is the default anchoring style in Forest?

Drawing linguistic phrase structure trees most of the time, I use the sn edges from the forest manual as a global default, with parent anchor=south, child anchor=north. This outputs the following sort ...
6
votes
1answer
37 views

Forest local versus global style

This is something that has been frustrating me for an hour or two. Usually I maintain forest styles locally within each image. I have one particular forest that has been driving me insane, but I am ...
5
votes
1answer
121 views

drawing complex dependency diagrams with tikz / forest

I want to draw the following Word Grammar diagram with tikz/forest: I am a great fan of forestand would like to have a style for such graphs, but I think this is non-trivial/impossible for this type ...
7
votes
1answer
88 views

Targeting proper parts of nodes in `forest`

I am using forest to construct trees. I have one (minor but persistent) issue: sometimes I would like to place a node at a point that is a proper part of (e.g.) a leaf, in particular so that I can ...
1
vote
0answers
35 views

! LaTex Error: File `forest.sty` not found [duplicate]

When I run a tikz code on my PC, the following error always stop me from producing the figure. ! LaTex Error: File forest.sty not found But my code is okay in Overleaf. My LaTex on ...
4
votes
2answers
74 views

Elementary forest question: meaning of calign, parent anchor and child anchor [closed]

Consider the following example: \documentclass[tikz,border=5pt]{standalone} \usepackage{forest} \begin{document} \begin{forest} for tree={ draw, } [center,calign=center [first, parent ...
6
votes
2answers
161 views

move the green box to the top of the right grey box

The following is the graph I modified from the forest style, but I encounter an problem when I try to move the green box to the top of the right grey box, I know the main problem is the tree style, ...
4
votes
2answers
66 views

Aligning nodes at the right periphery of the text area in forest

I have to typeset trees with huge AVMs in them: I want to do this with forest and the idea is to have all right nodes be aligned at the right periphery as it was done by hand in the picture above. ...
0
votes
1answer
21 views

Aligning siblings with complex content in forest

I have the following code and I want the AVMs to be aligned at the top. The two PHON values should be at the same height. I have the option base=top set for all nodes, but this does not work. ...
6
votes
2answers
250 views

Math content in forest

I'm trying to modify an example given in the forest manual. However, the template is setup in such a way that I'm not able to enter more "advanced" math contents, such as \nicefrac or \underset. In ...
2
votes
2answers
64 views

Draw a box containing the grandchild and add text at the bottom of box

I want to draw a minimal box which contains all the grandchilds (pink boxes), and move the text of deep green box to the bottom of the new box. How could I do it? codes: \documentclass{standalone} ...
7
votes
1answer
92 views

TikZ externalize fails with Forest

I'm having a hard time getting TikZ externalize and Forest to play nicely. Here is a MWE (text.tex): \documentclass{article} \usepackage[external]{forest} \tikzexternalize \tikzset{ ...
2
votes
1answer
44 views

How to align text boxes in forest?

I adopted Alenanno's code to draw the following graph, but I encounter a problem, that is, how to align the text boxes (pink boxes) in left? and codes are as follows: \documentclass{standalone} ...
1
vote
0answers
33 views

Align the forest from left to right [duplicate]

Recently, I applied cfr's code to what I wanted (see below). But I want to arrange this diagram from left to right in order to put into my book, that is, put the topmost box at the left side of page ...
4
votes
1answer
54 views

How to modify Forest nodes in Beamer overlays?

I would like to change a property, say the color, of a forest node between overlays in beamer. It is proposed elsewhere to use PGF's keys for this in the general case. However, this approach doesn't ...
3
votes
2answers
176 views

Writing info into a tree

I want to draw this tree, but I want the data on the branches to be parallel to the branch, not like the result I am getting Thank you! \documentclass[12pt,oneside,a4paper,fleqn]{report} ...
2
votes
2answers
40 views

Making branches closer in a tree

Suppose that I have the following tree... and I want to make only the second and third branches closer. Is that possible? \documentclass[12pt,oneside,a4paper,fleqn]{report} \usepackage{forest} ...
6
votes
2answers
191 views

Decision Tree with Labels on Both Sides of Line

I am trying to generate a decision tree similar to this scanned example: Notice that some branches have text on the top as well as the bottom. I have not figured out how to do this. I can get text ...
1
vote
3answers
72 views

Adding Short Lines Across Decision Tree Branch

I am creating decision trees using the 'forest' package and would like to add short lines across a branch to indicate that the decision is sub-optimal. Can this be done in 'forest'? I am attaching a ...
7
votes
2answers
226 views

Adding Triangles to LaTeX Decision Trees

I am using the 'forest' package in LaTeX in order to create decision trees with multiple decisions. I've got it mostly how I want it, except for two things: I'd like the circles at the leaves of the ...
2
votes
1answer
32 views

draw small lines

I have the following scenario tree \begin{forest} [,name=a,for tree={s sep=50pt,l sep=5cm,dot,grow=1}, [ ,name=b, edge=dashed [ ,name=c, edge=dashed ] [ ,name=i, edge=densely ...
2
votes
2answers
100 views

A scenario tree in latex

I know it's a bit tedious, but could someone please write me the latex code for below tree? Here's how I started \documentclass{article} \usepackage{amsmath} \usepackage{forest} \tikzset{ ...
2
votes
2answers
37 views

Family tree with two different line style using forest package

I'm trying to use forest package to draw a family tree in similar fashion like a folder. I'd like some children to be marked with dashed lines, because they are not descendents of the person, but are ...
3
votes
2answers
169 views

forest “every leaf node” and “every tree node” like syntax

I was seeing around that the forest package is better at drawing trees than tikz-qtree. I want to migrate my drawings, however, I can't find a way to easily format the tree. I see that there are ways ...
2
votes
1answer
82 views

How to compile tikz files into article?

I've been using forest to make logical proof tree. For my project I need to compile them all into a large file and add commentary which does not belong in the tree. Any advice on how to do that would ...
4
votes
2answers
78 views

Expansion in forest

I am trying to expand a macro as part of a style within a forest tree. Here's an MWE: \documentclass[tikz,border=5pt]{standalone} \usepackage{forest,ifthen} \begin{document} \bracketset{action ...
4
votes
2answers
153 views

Making forest tree with lots of text much narrower

I am having trouble getting a forest tree to fit on the page. I was wondering what techniques there are to squash the tree below so it doesn't take up so much horizontal space. Ideas I had (but have ...
0
votes
1answer
36 views

PGF Math error with blank node in forrest [duplicate]

\documentclass[12pt]{article} \usepackage{forest} \usepackage{gb4e,cgloss} \forestset{ sn edges/.style={for tree={parent anchor=south, child anchor=north,align=center,base=bottom{}}}, ...
7
votes
1answer
231 views

How to create a correctly aligned tree proof in logic with 4 branches, columns of line numbers and justifications?

I'm looking for a way to make a Logic Tree with three columns (line number, tree itself and commentary). I've tried using a tikz matrix, and it worked very well, except when I get more than two ...
6
votes
3answers
156 views

Autosegmental Representation in tikz-qtree

This is what I want to achieve and this: But all I've been able to make with tikz-qtree is the following: \documentclass[12pt,a4]{article} \usepackage[utf8]{inputenc} ...
6
votes
2answers
68 views

Changing the size of empty nodes in forest

I want to set the following picture: The following forestcode almost does it: \documentclass{article} \usepackage{forest} \begin{document} \begin{forest} for tree={fit=band,parent ...
5
votes
2answers
65 views

LaTeX Error: Missing \begin{document} with forest-GP1

I'm trying to use forest-GP1 which is a style in Zivanovic's forest-package (for phonological representation) found on github. I have added the .sty file to the same directory as the relevant .tex ...
1
vote
1answer
113 views

Upside-down trees in forest

I'm trying to typeset a tree which grows upwards using the forest package. The problem I have is that as soon as I leave the first level, branches start growing back down again. Here's the code: ...
11
votes
2answers
120 views

Two lines in a single node in Forest

I have recently switched from the tikz_qtree package to forest. Now I'm trying to change my trees to fit the forest coding. However, I can't find the way to let a single node contain two lines. I do ...
0
votes
1answer
30 views

Associating two children to one parent in Forest [duplicate]

I am trying to draw a nice multi-dominance. I find the gap between the two lines above "V" is ugly. Is there any way to move the lower end of the line in red square so that the two lines meet at one ...
7
votes
1answer
58 views

How to remove an unwanted line in forest?

\documentclass{article} \usepackage{forest} \begin{document} \begin{forest} [TP [DP] [T' [T] [VP [DP] [V', name=node [V] [DP] ] ]]] ...
4
votes
1answer
32 views

How can I set a style in `\forestset` which requires delayed calculations with the results of node walks?

What is the correct way to wrap the specification for the tree below into the my binomial style defined in \forestset and why? The following code works fine: ...
6
votes
2answers
260 views

Tikz Forest label positioning

I'm constructing a tree diagram using the forest package, and I want to label the edges. Usually, Tikz is quite good at avoiding a collision between the label and the edge, but if the branches of my ...
0
votes
1answer
47 views

forrest hierarchical diagram that will fit in landscape mode for 8.5“ by 11” document

Is there a way to use the pictured hierarchical diagram and load it into latex so that it fits into landscape on a 8.5" by 11" document that won't affect header and footer/page number? somewhat new to ...
1
vote
1answer
76 views

Is there a way to systematically ignore specific error messages?

When I compile my documents with a lot of trees, I often get the following error code: ! Dimension too large. <recently read> \pgf@xa l.1042 }} This error is due to some temporary ...
2
votes
2answers
161 views

Forest causing PdfLatex to run out of memory

I asked this question almost a year ago but did not have much luck. MikTex's PDFLaTeX has been updated since, but the error is still there: ! TeX capacity exceeded, sorry [save size=50000]. Full ...
3
votes
1answer
72 views

Arrows with texts in forest?

\documentclass{article} \usepackage[margin=.8in]{geometry} \usepackage{forest} %main + for elongation of two branches of a node \usepackage{tikz-cd} \begin{document} \begin{forest} baseline, for ...
6
votes
1answer
106 views

How can I draw -X in the forest package?

I want to draw a dead-end in forest. edge={-X} doesn't work. Example: \documentclass[a4paper]{article} \usepackage[english]{babel} \usepackage[utf8x]{inputenc} \usepackage{amsmath} ...
5
votes
1answer
142 views

setting all nodes of a tree in italics with forest

I want to define a style for setting type hierarchies with forest and the types should come out in italics. I read the manual, but ... I found some examples that use the content of a node and do ...
5
votes
1answer
107 views

Lazy Evaluation in Forest Package?

I'm using the forest package to draw logic circuits, and I'm trying to customize the style. I want the inputs to be aligned, so I write this macro: \newcommand{\inp}[1]{[#1,tier=in]} But when the ...
2
votes
1answer
38 views

Using Forest Package in Newenvironment

I'm trying to use the forest package to draw circuits, so I want to define a "circuit" environment that is a wrapper around the forest environment. But defining a newenvironment runs into problems. ...