Description Usage Arguments Details Value See Also Examples
This is the stringi's equivalents of the built-in
paste
function.
1 2 3 4 5 |
... |
character vectors which corresponding elements should be concatenated |
sep |
single string; separates terms |
collapse |
single string; separates the results |
stri_c
and stri_paste
are aliases for
stri_join
. Use whichever you want, they are
equivalent.
If collapse
is not NULL
, then the result will
be a single string. Otherwise, you will get a character
vector of length equal to the length of the longest
argument.
If any of the arguments in '...
' is a vector of
length 0 (not to be confused with vectors of empty
strings), then you will get a 0-length character vector in
result.
If collapse
or sep
has length > 1, then only
first string will be used.
In case of any NA
, NA
is set to the
corresponding element.
Returns a character vector.
Other join: stri_dup
;
stri_flatten
1 2 3 |
[1] "1a" "2b" "3c" "4d" "5e" "6f" "7g" "8h" "9i" "10j" "11k" "12l"
[13] "13m" "1n" "2o" "3p" "4q" "5r" "6s" "7t" "8u" "9v" "10w" "11x"
[25] "12y" "13z"
[1] "abc...###...1" "123...###...2" "<U+0105><U+0104>...###...3"
[4] "abc...###...4" "123...###...5"
Warning message:
In stri_join(c("abc", "123", "<U+0105><U+0104>"), "###", 1:5, sep = "...") :
longer object length is not a multiple of shorter object length
[1] "abc...###...1?123...###...2?<U+0105><U+0104>...###...3?abc...###...4?123...###...5"
Warning message:
In stri_join(c("abc", "123", "<U+0105><U+0104>"), "###", 1:5, sep = "...", :
longer object length is not a multiple of shorter object length
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.