Learn R Programming

soundcorrs (version 0.2.0)

read.soundcorrs: Read data for a single language from a tsv file.

Description

Read the data for one language, from a file in the wide format, and combine it with metadata into a soundcorrs object. To obtain a soundcorrs object containing data for multiple languages, see merge.soundcorrs.

Usage

read.soundcorrs(file, name, col.aligned, transcription, separator = "\\|")

Arguments

file

[character] Path to the data file in the wide format.

name

[character] Name of the language.

col.aligned

[character] Name of the column with the aligned words.

transcription

[character] Path to the file with the transcription.

separator

[character] String used to separate segments in col.aligned. Defaults to "\|".

Value

[scOne] An object containing the data and metadata for one language.

Examples

Run this code
# NOT RUN {
# path to sample data in the "wide format"
fNameData <- system.file ("extdata", "data-capitals.tsv", package="soundcorrs")
# path to a sample transcription
fNameTrans <- system.file ("extdata", "trans-common.tsv", package="soundcorrs")
ger <- read.soundcorrs (fNameData, "German", "ALIGNED.German", fNameTrans)
# }

Run the code above in your browser using DataLab