protectMetachar: Protect Metacharacters

Description Usage Arguments Details Value Author(s) See Also Examples

Description

Add backslashes before any metacharacters found in a string.

Usage

1

Arguments

x

character vector

Details

This function is used to protect strings containing metacharacters so that the metacharacters can be treated as ordinary characters in string matching functions operations.

Value

A character vector of the same length as x in which two backslashes have been inserted before any metacharacter.

Author(s)

Gordon Smyth

See Also

An overview of LIMMA functions for reading data is given in 03.ReadingData.

Examples

1
2
# without protectMetachar, this would be no match
grep(protectMetachar("Ch1 (mean)"),"Ch1 (mean)")

richierocks/limma2 documentation built on May 27, 2019, 8:47 a.m.