Convert various input as features to a vector for fucntions that do not support multi-word features e.g. dfm_select, sequences, collocations.

features2vector(features)

Arguments

features

the input features, one of:

  • character vector, whose elements will be split on whitespace;

  • list of characters, consisting of a list of token patterns, separated by white space;

  • tokens object;

  • dictionary object;

  • collocations object.

Value

an unnamed vector of features