R/as_data_frame.R
as_data_frame.Rd
Wrapper around as.data.frame. In contrast it sets stringsAsFactors=FALSE and allows to pass a vectors of column names.
as.data.frame
stringsAsFactors=FALSE
as_data_frame(x, col.names = NULL, ...)
[object] Any R object that can be coerced into a data frame.
object
[character | NULL] Optional character vector of column names.
character
NULL
[any] Further arguments passed down to as.data.frame.
any
A data frame.
x = list(a = 1:2, b = c("K", "L")) y = as_data_frame(x, col.names = c("C1", "C2"))