vec_char_redu {signatureSearch} | R Documentation

## Reduce Number of Character

### Description

Reduce number of characters for each element of a character vector by replacting the part that beyond Nchar (e.g. 50) character to '...'.

### Usage

    vec_char_redu(vec, Nchar = 50)

### Arguments

`vec` | character vector to be reduced
`Nchar` | integer, for each element in the vec, number of characters to remain

### Value

character vector after reducing

### Examples

    vec <- c(strrep('a', 60), strrep('b', 30))
    vec2 <- vec_char_redu(vec, Nchar=50)

[Package signatureSearch version 1.1.5 Index]