print(x, ...)
x | a factor object. |
... | additional arguments. |
f <- factor(c()) print(f) # factor(0) # Levels:f <- factor(c("a", "b", "c")) print(f) # [1] a b c # Levels: a b c
f <- factor(c("a", "b", "c"), ordered=TRUE) print(f) # [1] a b c # Levels: a < b < c
f <- factor(c("a", "b", "c")) print(f, quote=TRUE) # [1] "a" "b" "c" # Levels: "a" "b" "c"
f <- factor(c("a", "b", "c")) print(f, max.levels=2) # [1] a b c # 3 Levels: a ... c