transcripts_cure {act}R Documentation

Cure all transcript objects in a corpus

Description

Transcript object may contain errors, e.g. because of defect annotation input files or user modifications. This function may cure some of these errors in all transcript objects of a corpus. - Annotations with reversed times: annotations with endSec lower than startSec will be deleted. - Overlapping annotations: earlier annotations will end where the next annotation starts. - Annotations below 0 sec: Annotations that are starting and ending before 0 sec will be deleted; Annotations starting before but ending after 0 sec will be truncated. - Missing tiers: Tiers that are present in the annotations but missing in the list of tiers in @tiers of the transcript object will be added.

Usage

transcripts_cure(
  x,
  filterTranscriptNames = NULL,
  annotationsWithReversedTimes = TRUE,
  overlappingAnnotations = TRUE,
  annotationsWithTimesBelowZero = TRUE,
  missingTiers = TRUE,
  showWarning = FALSE
)

Arguments

x

Corpus object.

filterTranscriptNames

Vector of character strings; names of the transcripts to be included.

annotationsWithReversedTimes

Logical; If TRUE annotations with reversed times will be deleted

overlappingAnnotations

Logical; If TRUE overlapping annotations will be corrected.

annotationsWithTimesBelowZero

Logical; If TRUE annotations before 0 sec will be corrected.

missingTiers

Logical; If TRUE tiers missing in @tiers slot of the transcript object will be added.

showWarning

Logical; If TRUE a warning notice will be shown upon correction.

Value

Corpus object;

See Also

transcripts_cure_single

Examples

library(act)

# The example corpus does not contain any errors.
# But let's use the function anyway.
x<- act::transcripts_cure(examplecorpus)
x@history[[length(x@history)]]

# See \code{act::cure_transcript} for actual examples.


[Package act version 1.1.9 Index]