Description Usage Arguments Value Author(s) Examples
Convert certain columns of a data.frame to character type
1 | charify(dat, cols)
|
dat |
data.frame |
cols |
character. Names of columns to be converted. |
data.frame
Kaiyin Zhong, Fan Liu
1 2 3 4 5 6 7 | ## Not run:
x = data.frame(x = 1:3, y= 2:4)
all(colClasses(x) == c("integer", "integer"))
x = charify(x, "x")
all(colClasses(x) == c("character", "integer"))
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.