vctrs icon indicating copy to clipboard operation
vctrs copied to clipboard

Return data frames of class `c("tbl", "data.frame")`

Open lionel- opened this issue 4 years ago • 3 comments

To get nice printing when tibble is loaded:

vctrs::new_data_frame(
  list(x = list(1, 2)),
  class = "tbl"
)
#> # A data frame: 2 × 1
#>   x
#>   <list>
#> 1 <dbl [1]>
#> 2 <dbl [1]>

lionel- avatar May 28 '21 09:05 lionel-

Consider vec_count() output, i.e. #1632

DavisVaughan avatar Aug 30 '22 13:08 DavisVaughan

If it turns out to be too confusing to print dfs like tibbles (but after some practice in rlang I think it's fine), we can just improve the print method in pillar, e.g. we could have a "base" qualifier in bold red in the header.

lionel- avatar Aug 30 '22 13:08 lionel-

Potential set of candidates

vec_count
vec_split
vec_group_loc
vec_locate_sorted_groups
vec_unrep

# this would be fine as a base data frame,
# always returns integer columns, but may be a candidate
vec_locate_matches

DavisVaughan avatar Sep 15 '22 14:09 DavisVaughan