OT learning 2.2. Inside the grammar

You can save an OTGrammar grammar as a text file by choosing Save as text file... from the Save menu of the Objects window. For the NOCODA example, the contents of the file will look like:

File type = "ooTextFile"
Object class = "OTGrammar 2"
decisionStrategy = <OptimalityTheory>
leak = 0
2 constraints
constraint [1]: "N\s{O}C\s{ODA}" 100 100 1 ! NOCODA
constraint [2]: "P\s{ARSE}" 90 90 1 ! PARSE
 
0 fixed rankings
 
2 tableaus
input [1]: "pat" 2
    candidate [1]: "pa" 0 1
    candidate [2]: "pat" 1 0
input [2]: "pa" 1
    candidate [1]: "pa" 0 0

To understand more about this data structure, consult the OTGrammar class description or click Inspect after selecting the OTGrammar object. The "\s{...}" braces ensure that the constraint names show up with their traditional small capitals (see Text styles).

You can read this text file into Praat again with Read from file... from the Open menu in the Objects window.

Links to this page


© ppgb, January 29, 2011