Category Archives: trees

Drawing linguistic structure trees

The LaTeX way

I use LaTeX to make my trees—the qtree package for simple trees, and xyling for anything more complicated like prosodic structures, Hasse diagrams, etc. For detailed instructions and links, see the LyX Wiki for Linguists. This page explains not only how to do syntax trees but also how to draw moraic structures, how to include IPA in a syntax tree, and so on.

Standalone applications

There are several standalone programs, both webapps and desktop apps, that you can use to enter tree structures, and they will render the structures as pictures for you. I likeĀ  phpSyntaxTree: Given the input [S [NP [N Trees]] [VP [V grow] [PP in apps]]], this produces a PDF with the following image.

php syntax tree demo

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

It also supports Unicode now so you can use IPA in your trees as well as have math symbols in your labels.

For desktop apps specific to your OS, do a search–there is definitely stuff out there for Windows and Macs, although there may no longer be support for the apps because they tend to be a labor of love sort of thing.

The Fingerpainting Method

In Libre Office, Microsoft Office, and no doubt other programs, you can draw the trees by tabbing the words into position and adding the lines using the line drawing tool. Here is what I got when I did this in Libre Office. (In order to make it look like that, I had to individually right-click on every line and change the color to black, because it defaults to blue and I couldn’t stand that and I could not be assed to figure out where the defaults are.) So, as you can see, the method is slow and ugly, but it has some benefits.

libre office line drawn tree

  1. It works when you do not have an internet connection.
  2. The tree is entirely contained in your document and uses the same fonts as your text, so even though you get an ugly tree, the fonts match
  3. There is no need to worry about embedding fonts in your PDF file, unlike the Arboreal method (next).
  4. You do not have to learn even the rudimentary bracketing syntax that phpSyntaxTree and others require, so if you are really afraid of any sort of structure and notations, this method is for you. Then again, if you are this afraid of structure, you should probably give up because linguistics might not be for you.

 

 

 

Arboreal and Moraic

This is an old approach to drawing trees. You tab or space your words into position and switch to the font, which provides characters that look like lines at different angles. There’s a triangle or two. The output looks more consistent than the fingerpainting method above. Notice that the screenshot on the right has the red spellchecker underline–it’s because the lines are actually characters, and the LibreOffice spellchecker treats them as (ill-formed) text. The red lines would not be visible in the PDF.

 

 

 

 

 

This method has many downsides, however.

  1. The fonts are proprietary and cost $20 each.
  2. These predate Unicode so modern computers don’t know what to do with them unless they have been converted to pictures first. So these fonts need to be explicitly embedded in the PDF or else they render as capital Gs, etc.
  3. The limitations of the characters restrict what types of trees you can draw—for example, the triangles only come in a few sizes.
  4. I spent about 10 minutes henpecking around the keyboard looking for the right characters to show you, and the font kept switching back to the default text font. The key map on my OS did not even know how to render these characters, so I was flying blind.

 

Comments Off on Drawing linguistic structure trees

Filed under international phonetic alphabet, trees, tutorials