[R] regular expression

Bernd Weiss bernd.weiss at uni-koeln.de
Fri Apr 1 02:32:25 CEST 2011


Am 31.03.2011 19:31, schrieb array chip:
> Hi, I am stuck on this: how to specify a match pattern that means not
> to include "abc"?
>
> I tried:
>
> grep("^(abc)", "hello", value=T) should return "hello".

 > grep("[^(abc)]", "hello", value=T)
[1] "hello"


HTH,

Bernd



More information about the R-help mailing list