From edward.m at psu.ac.th  Thu Mar  8 21:05:36 2018
From: edward.m at psu.ac.th (Edward McNeil)
Date: Fri, 9 Mar 2018 03:05:36 +0700
Subject: [Rd] reshape function: allow split argument to include perl
Message-ID: <5373b30a8ed891599ce278523c4c926a.squirrel@webmail.psu.ac.th>

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



[Rd] reshape function: allow split argument to include perl
Edward McNeil