Learn R Programming

vocaldia (version 0.8.4)

getTurnType: getTurnType: return type of turn

Description

Identify turn types

Usage

getTurnType(
  df,
  i,
  individual = FALSE,
  nodecolumn = "speaker",
  noPauseTypes = F
)

Value

a string containing the turn type or identifier.

Arguments

df

a data frame consisting, minimally, of a column for vocalisation/pause start times, a column for end times, and a column identifying the speaker, speaker role or 'Floor' (for silences).

i

the identifier (index number) whose type will be returned

individual

if TRUE, return the identifier, a Pause or Grp

nodecolumn

the name of the column containing the node (speaker) name (e.g. 'speaker', 'role').

noPauseTypes

if TRUE, ignore distinctions between pauses (SwitchingPause, GrpSwitchingPause, etc)

Details

Return one of Vocalisation, GrpVocalisation, ... or identifier.

Examples

Run this code
data(vocdia)
atddia[1:10,]
getTurnType(atddia, 3, nodecolumn='role') ## a vocalisation
getTurnType(atddia, 4, nodecolumn='role') ## a pause

Run the code above in your browser using DataLab