Generate data.tables.
Arguments
- rows
Number of rows of the generated data frame. If
rows
is a single number all data frames will have this number of rows. Ifrows
is a numeric vector of length 2 it will produce data frames with rows between a minimum and maximum, inclusive. For examplerows = c(1L, 10L)
would produce data frames with rows between 1 and 10. To produce empty tibbles setrows = 0L
or a range likerows = c(0L, 10L)
.- cols
Number of columns of the generated data frame. If
cols
is a single number all data frames will have this number of columns. Ifcols
is a numeric vector of length 2 it will produce data frames with columns between a minimum and maximum, inclusive. For examplecols = c(1L, 10L)
would produce data frames with columns between 1 and 10. To produce empty tibbles setcols = 0L
or a range likecols = c(0L, 10L)
.- any_na
Whether
NA
values should be allowed.
Examples
any_data.table(rows = 3L, cols = 3L) %>% show_example()
#> ...1 ...2
#> 1: 8):1i 2077-07-06,1599-06-09,2261-11-09,2188-09-27
#> 2: :olro BBu}P,.)WmP%U|
#> 3: K$z7 0,-235185452, 56836493, 41522128, 905553740,-406054955
#> ...3
#> 1: TRUE
#> 2: FALSE
#> 3: FALSE