Hi,
I'd like to request that the "split" argument of the reshape function include 
the perl
argument so that "splitting" is more flexible.

An example is if the varying argument contains "Q1.1.1, Q1.1.2, Q1.2.1, Q1.2.2, 
" etc.
Splitting on the last "dot" seems to be only possible using perl.

> x <- c("Q1.1.1", "Q1.1.2", "Q1.2.1", "Q1.2.2")
> strsplit(x, "(\\.)(?=[^\\.]$)", perl=TRUE)
[[1]]
[1] "Q1.1" "1"

[[2]]
[1] "Q1.1" "2"

[[3]]
[1] "Q1.2" "1"

[[4]]
[1] "Q1.2" "2"

Thanks.
-- 
Edward McNeil

______________________________________________
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel

Reply via email to