Learn R Programming

rsyntax (version 0.1.4)

get_branch_id: Add the branch id as a column to the tokenindex

Description

After splitting trees into branches

Usage

get_branch_id(tokens)

Arguments

tokens

A tokenindex

Value

the tokenindex

Examples

Run this code
# NOT RUN {
tokens = tokens_spacy[tokens_spacy$doc_id == 'text4',]
tokens = as_tokenindex(tokens)

# }
# NOT RUN {
tokens2 = isolate_branch(tokens, relation = 'relcl', copy_parent = TRUE)
get_branch_id(tokens2)
# }

Run the code above in your browser using DataLab