Learn R Programming

odfWeave (version 0.4.1)

odfCat: Concatenate and Print in Native ODF

Description

Outputs the objects, concatenating the representations, and sandwiches the output between XML tags.

Usage

odfCat(..., sep = " ", trim = FALSE, 
   digits = max(3, getOption("digits") - 3), nsmall = 0,
   width = NULL, na.encode = TRUE, scientific = NA)

Arguments

...
R objects (see Details for the types of objects allowed).
sep
character string to insert between the objects to print.
trim
used to convert numeric data to character using format
digits
used to convert numeric data to character using format
nsmall
used to convert numeric data to character using format
width
used to convert numeric data to character using format
na.encode
used to convert numeric data to character using format
scientific
used to convert numeric data to character using format

Details

odfCat is an analog to cat and is useful for producing output in user-defined functions. It converts its arguments to character strings, concatenates them, separating them by the given 'sep=' string. It then sandwiches the text between tags, and then outputs them. cat uses an internal function, so there will be some differences between cat and odfCat. For example, factors are naively converted to character and numeric data are converted to character.

Since the text is embedded in ODF tags escaped characters (e.g. ) don't have any effect. Exceptions are " and '. a character strng of class odfCat

See Also

cat, format

Examples

Run this code
odfCat(""hello world"")
odfCat("this are the first letters", letters[1:5])
odfCat("some random normal data:", rnorm(5))

Run the code above in your browser using DataLab