PhonologicalCorpusTools / CorpusTools

Phonological CorpusTools
http://phonologicalcorpustools.github.io/CorpusTools/
GNU General Public License v3.0
111 stars 16 forks source link

"switch segments" option not working #635

Open kchall opened 7 years ago

kchall commented 7 years ago

When segments are selected (e.g., for a ProD analysis), there's an option to switch the order of the segments in the function dialogue box. This works insofar as displaying the segments is concerned, but internally, the order hasn't been switched.

E.g.:

IPHOD corpus; calculate ProD of [EY] and [EH] in the environment [-syll] __ #.

The "natural" order of the segments is [EH], [EY], and using this order works -- there are 275 instances of [EY] and only 6 of [EH] (as expected for lax vowels in open syllables):

image

image

But if we switch the order of the segments in the original dialogue box, we get the same results for the "second segment", which would mean we're getting 275 tokens of [EH], which is not accurate:

image

image

jsmackie commented 7 years ago

After some testing, it seems like this bug is only cropping up when an environment is selected. Without environments (e.g. "FREQ-ONLY") the numbers looks correct.

kchall commented 7 years ago

Agreed that the underlying bug seems to be fixed. The order of columns in the output window is a bit odd, though:

image

In particular, the frequency of the second segment is listed first, and not adjacently to the frequency of the first segment.