strsplit3: String splitting shortcut

Description Usage Arguments Value Author(s) See Also Examples

View source: R/cladoRcpp.R

Description

strsplit returns the results inside a list, which is annoying. strsplit3 shortens the process.

Usage

1

Arguments

x

A string to split

...

Other arguments to strsplit. The argument split is required.

Value

out The output from inside the list.

Author(s)

Nicholas J. Matzke matzke@berkeley.edu

See Also

strsplit

Examples

1
2
3
4
5
6
7
8
9
# strsplit returns the results inside a list element
out = strsplit("ABC", split="")
out
# I.e....
out[[1]]

# If this is annoying/ugly in the code, use strsplit3:
out = strsplit3("ABC", split="")
out

Example output

[[1]]
[1] "A" "B" "C"

[1] "A" "B" "C"
[1] "A" "B" "C"

cladoRcpp documentation built on May 30, 2017, 6:38 a.m.

Search within the cladoRcpp package
Search all R packages, documentation and source code