vectorToDB | R Documentation |
Converts a numeric, integer or character vector (multiple elements) to a single element character vector (a string)
vectorToDB(
dataVector = NA,
collapseChar = ";",
formatNumbers = FALSE,
removeNA = FALSE,
...
)
dataVector |
the data to be converted: integer, numeric, character or logical. Other data types have not been tested |
collapseChar |
the character to be used as seperator in the end result. Note: this seperator should not be present in the dataVector (especially after transformation) as it will give problems when using the DBToVector function. |
formatNumbers |
boolean specifying whether the dataVector should be formatted using the base::format function |
removeNA |
if TRUE then all NA values are removed before the result is transformed into a single element character vector |
... |
further arguments to be passed onto to base::format, see ?base::format for more information. Ignored when formatNumbers == FALSE |
a single element character vector
dataVectors of the 'factor' class are changed into character class!
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.