This package provides a shiny app used to modify F0 pitch pulses held in a spreadsheet.
If you use this software in your research, please cite the following paper:
Sostarics, T., & Cole, J. (2024). PitchMendR: A Tool for the Diagnosis and Treatment of F0 Irregularities. In Proceedings of Speech Prosody 2024.
Bibtex:
@inproceedings{sostarics24speechprosody,
author={Thomas Sostarics and Jennifer Cole},
title={{PitchMendR: A Tool for the Diagnosis and Treatment of F0 Irregularities}},
year=2024,
booktitle={Proc. Speech Prosody 2024},
pages={289--293},
doi={10.21437/SpeechProsody.2024-59}
}
You can install the development version from GitHub with:
# install.packages("devtools")
devtools::install_github("tsostarics/PitchMendR")
You can launch the editor GUI like so:
library(PitchMendR)
openEditor()
You will be brought to the Setup
page, where the current working directory is shown.
The input directory will be automatically set to the directory containing a demo file demo_data.csv
.
The output directory is set to the current working directory (.
)
Files in the input directory that you can load are shown in the Files Available dropdown box.
Once you select a file from the box, press the big blue Load File
button in the top right corner.
The app assumes the following columns exist by default, but can be changed in the Settings pane.
Filename
column specifying the individual pitch contourst_ms
column to use as the x-axis timestamp values for the pulsesf0
column to use as the y-axis valuesThese are the default outputs from PraatSauce, which exports a single csv file containing information about multiple processed files.
If any of these columns are not found in the dataset, you'll be brought to the Settings
page where you can change the column name mappings.
Once you've set the column names correctly you can try loading the file again.
There are three main sections, from right to left:
[Show line]
: Toggles whether a line is drawn through retained pulses in the plot[<]
and [>]
: Navigate to the previous/next file[Save file]
: Saves file to the output directory. If it exists, it will be overwritten.[Toggle Pulses]
: Select points in the plot area, then toggle whether they should be removed or kept[Keep]
: Keep selected pulses[Remove]
: Remove selected pulses[Halve Pulses]
: Divide pulse Hz values by 2, correcting for doubling errors[Double pulses]
: Multiply pulse Hz values by 2, correcting for halving errors[Plot matches]
to plot only those files whose filenames match the pattern. Set to .
to show all files.[Plot Brushed Files]
button to narrow in on those selected files.Additional toggles are available in the retractable sidebar.
As you inspect files, the app wil keep track of which files you've looked at and will move them from the "Unchecked Files" set to the "Checked Files set".
You can mark all currently plotted files as checked using the [Check off plotted files]
button.
Given a path to a praat executable (on windows) or a praat command (on Mac/Linux), as well as a directory of audio files and (optionally) textgrids, you can send files from PitchMendR to Praat. Simply press the "Send to Praat" button and the currently opened files will be opened in Praat. If you select a region on the plot before pressing the button, when looking at a single file, the selected region will also be sent to Praat, highlighting the same exact region. Note that the X-axis must be on the same scale (i.e., seconds) for this to work properly. You can press the Clear Praat Files button to automatically clear all the files in the objects pane, which is useful after loading a bunch of files.