Data Frames
Tibbles are a re-engineered data frame.
Contents
Installation
The tibble package is commonly used through Tidyverse.
Usage
A tibble is instantiated like:
> t1 <- tibble(foo = c(1,2,4),
bar = c("a","b","c"),
constant10 = 10)
> t2 <- as_tibble(data.frame(foo = c(1,2,4),
bar = c("a","b","c"))
> t3 <- as_tibble(matrix(1:9, nrow=3))In comparison to data frames, input column vectors must either be the same length, or be a scalar value. Only scalars are recycled.
Note that tibbles store each column separately, and that tibbles instantiate the columns sequentially. It is possible to declare a column as a function of prior columns.
Tibbles are multiclassed as both data.frame and tbl_df.
