Thx for the hint, but what would I have used if "b","c" and "d"
were values of a dataframe for instance?

Stéphane.

Gabor Grothendieck a écrit :
> Try this:
>
>> grep("b|c|d", letters, value = TRUE)
> [1] "b" "c" "d"
>
> On 10/16/06, Stéphane CRUVEILLER <[EMAIL PROTECTED]> wrote:
>> Dear R-users,
>>
>> is there a way to pass a list of patterns to the grep function? I
>> vaguely remember something with %in% operator...
>>
>>
>> Thanks,
>>
>>
>> Stéphane.
>>
>>
>>
>> -- 
>> "La science a certes quelques magnifiques réussites à son actif mais
>> à tout prendre, je préfère de loin être heureux plutôt qu'avoir raison."
>> D. Adams
>> -- 
>> AGC website <http://www.genoscope.cns.fr/agc>
>>        Stéphane CRUVEILLER Ph. D.
>> Genoscope - Centre National de Séquencage
>> Atelier de Génomique Comparative
>> 2, Rue Gaston Cremieux CP 5706
>> 91057 Evry Cedex - France
>> Phone: +33 (0)1 60 87 84 58
>> Fax: +33 (0)1 60 87 25 14
>> [EMAIL PROTECTED]
>>
>> ______________________________________________
>> [email protected] mailing list
>> https://stat.ethz.ch/mailman/listinfo/r-help
>> PLEASE do read the posting guide 
>> http://www.R-project.org/posting-guide.html
>> and provide commented, minimal, self-contained, reproducible code.
>>

-- 
"La science a certes quelques magnifiques réussites à son actif mais
à tout prendre, je préfère de loin être heureux plutôt qu'avoir raison." 
D. Adams
-- 
AGC website <http://www.genoscope.cns.fr/agc>
        Stéphane CRUVEILLER Ph. D.
Genoscope - Centre National de Séquencage
Atelier de Génomique Comparative
2, Rue Gaston Cremieux CP 5706
91057 Evry Cedex - France
Phone: +33 (0)1 60 87 84 58
Fax: +33 (0)1 60 87 25 14
[EMAIL PROTECTED]

______________________________________________
[email protected] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to