![]() ![]() Since I've made this script before I have a more specific idea of what I want to do. Your outline might be different, or more general than mine. Also take a look at the sample spreadsheet in praatTutorial/sampleData/formantScript/output, which is what we're going to generate.Īs always, create a plan with comments, mine is below. Take a look at one of the wav and text grid file pairs in praatTutorial/sampleData/formantScript/data. We can add that functionality in later if we want. While we're going to make a quality script, I'm not going to worry at this point about making it really easy to use for non-scripters. As a bonus, we'll read in a settings file, so that we can customize the values to read the formants for specific individuals. The plan is to loop through every wav file in a directory, open its TextGrid (we assume it has the same name), get F1 and F2 values for every interval, and write it to a spreadsheet. No peeking until you've genuinely tried! (If you STILL haven't downloaded the accompanying files, click on the menu above to go to the download page.) ![]() If you find a better way of doing something, share! The final version I have is in praatTutorial/sampleData/formantBatch.praat. I recommend you try to build the script yourself, and then come back and see how I did it. I would definitely use your fancier text editor with syntax highlighting (see this earlier page), and use the workflow we talked about where you only edit in the nice editor, and "Reopen from file" in Praat's scripting editor. Consider this an exam, covering most everything we've learned so far. Long example: Extracting formant values to a spreadsheet ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |