Minimal Pairs

I wrote this PERL script in order to output minimal pairs from a document.  To use this properly, you need to take a document and save it as text.  Then you need to substitute items in the text so that each phoneme has a unique ASCII code.  I highly recommend a key-item pair so you can convert the text back and forth as needed.

Then make sure that PERL is installed on your computer.

Then, from your command-line, go to the directory with both this .pl file AND your text file, and type in the relevant information in this format:

perl {input.txt} {output.txt} {difference} {minimum size}

difference should be kept at 1 unless you want non-minimal pairs (not well tested)

Minimum size represent the minimum word size you wish to capture.

Output will have columns of the minimal pairs with the structure

minimal pair 1 | minimal pair 2 | phoneme 1 | phoneme 2


Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.