stri_dup | R Documentation |
Duplicates each str
(e1
) string times
(e2
) times
and concatenates the results.
stri_dup(str, times)
e1 %s*% e2
e1 %stri*% e2
str , e1 |
a character vector of strings to be duplicated |
times , e2 |
an integer vector with the numbers of times to duplicate each string |
Vectorized over all arguments.
e1 %s*% e2
and e1 %stri*% e2
are synonyms
for stri_dup(e1, e2)
Returns a character vector.
Marek Gagolewski and other contributors
The official online manual of stringi at https://stringi.gagolewski.com/
Gagolewski M., stringi: Fast and portable character string processing in R, Journal of Statistical Software 103(2), 2022, 1-59, \Sexpr[results=rd]{tools:::Rd_expr_doi("10.18637/jss.v103.i02")}
Other join:
%s+%()
,
stri_flatten()
,
stri_join_list()
,
stri_join()
stri_dup('a', 1:5)
stri_dup(c('a', NA, 'ba'), 4)
stri_dup(c('abc', 'pqrst'), c(4, 2))
"a" %s*% 5
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.