replace_itemLabels: Replace item labels

Description Usage Arguments See Also Examples

View source: R/emuR-autoproc_annots.R

Description

Replace the labels of all annotation items, or more specifically of attribute definitions belonging to annotation items, in an emuDB that match the provided origLabels character vector which the corresponding labels provided by the newLabels character vector. The indicies of the label vectors provided are used to match the labels (i.e. origLabels[i] will be replaced by newLabels[i]).

Usage

1
2
3
4
5
6
7
replace_itemLabels(
  emuDBhandle,
  attributeDefinitionName,
  origLabels,
  newLabels,
  verbose = TRUE
)

Arguments

emuDBhandle

emuDB handle object (see load_emuDB)

attributeDefinitionName

name of a attributeDefinition of a emuDB where the labels are to be replaced

origLabels

character vector containing labels that are to be replaced

newLabels

character vector containing labels that are to replaced the labels of origLabels. This vector has to be of equal length to the origLabels vector.

verbose

Show progress bars and further information

See Also

load_emuDB

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
## Not run: 

##################################
# prerequisite: loaded ae emuDB 
# (see ?load_emuDB for more information)

# replace all "I" and "p" labels with "I_replaced" and "p_replaced"
replace_itemLabels(ae, attributeDefinitionName = "Phonetic", 
                       origLabels = c("I", "p"), 
                       newLabels = c("I_replaced", "p_replaced"))


## End(Not run)

emuR documentation built on June 11, 2021, 5:10 p.m.