Description Usage Arguments Details Value Author(s) See Also Examples
Returns a vector of basic classes of the colums of a dataframe.
1 | colClasses(x)
|
x |
a dataframe. |
Since the return value is a vector with one element per colunm, column with multiple classes (such as ordered
and factor
) see their classes simplified as the last class from the class vector.
A named vector of the same length as ncol(x)
and whose names equal names(x)
.
Antoine Filipovic Pierucci
1 2 | tab <- data.frame(a = 1, b = "e", c = gl(1, 1), stringsAsFactors = FALSE)
colClasses(tab)
|
a b c
"numeric" "character" "factor"
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.