I think of text, grammars that parse the text, and the syntax trees (data) generated by a parser as a triangle. Most of the time in computerland, people doing something with this triangle are interested in converting a text into a tree using a parser.
Every once in a while I need to write a parser. My first serious parser was in the late 90's, for a radio station that needed each week to convert a large plain-text weekly email to tables of venues and shows. For that, I used a version of Bison (yacc) that allowed me to write actions in Perl./users/yary/2016/02/index.html