placesfert.blogg.se

Praat script extract intervals
Praat script extract intervals










praat script extract intervals

Which version you should use depends on your situation. Change which version of the command is commented and uncommented, and run it again. Now to make sure both commands work, click on a different object like "Sound ba", comment out the command you don't want to test (put a hashtag in front of one of the selectObject commands), and run the code.

praat script extract intervals

In a blank scripting window, type in the two following ways we can select the object "Sound a", adjusting the numbers to work with what you currently have open. The numbering starts at 1 when you open Praat, and will keep going up as you create more objects or open more files. Look to the left of each object, and note that they have been assigned a unique number. There are basically two ways we can select files in Praat: by using the object's name or by using its number in the object window.

#Praat script extract intervals how to

Hopefully you now see plainly why we need to learn how to select objects in Praat via script: we won't get very far without it. This should generate an error saying that the given command is not available, which is true, because that command is only available when a text grid is selected, and right now a sound is selected (other times this error simply means you've spelled the command wrong). Open a Praat scripting window, type this in, and run it: What we want to note here is that we have different commands available to us when different object types are selected. Now select a sound and its corresponding TextGrid together (ctrl), and look at the available commands. Now click on a text grid and look at the commands. Though we already went through this, click on a sound file and look at the available commands on the right. TextGrid files in sampleData/ (if you haven't downloaded the accompanying files, go to the Downloads page from the top right menu).












Praat script extract intervals