Learn R Programming

RBERT (version 0.1.11)

is_control: Check whether `char` is a control character.

Description

(R implementation of _is_control from BERT: tokenization.py.)

Usage

is_control(char)

Arguments

char

A character scalar, comprising a single unicode character.

Value

TRUE if char is a control character.

Details

"\t", "\n", and "\r" are technically control characters but we treat them as whitespace since they are generally considered as such.