Learn R Programming

pvar (version 1.0.6)

ConcatenateStrings: Concatenate strings

Description

Concatenate Strings

Usage

x %.% y

Arguments

x, y
strings that should be concatenated.

Value

  • A character string of the concatenated values.

Details

The same result may be achieved with paste, but this function is more user friendly then you need to add to strings.

See Also

paste

Examples

Run this code
paste("I ", "love ", "R.", sep="")
"I " %.% "love " %.% "R."

x = c(2,1,6,7,9)
paste("The length of vector (", paste(x , sep="", collapse =","), ") is ", length(x) , sep="")
"The length of vector (" %.% paste(x , sep="", collapse =",") %.% ") is " %.% length(x)

Run the code above in your browser using DataLab