Generate data.tables.
Arguments
- rows
Number of rows of the generated data frame. If
rowsis a single number all data frames will have this number of rows. Ifrowsis 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 = 0Lor a range likerows = c(0L, 10L).- cols
Number of columns of the generated data frame. If
colsis a single number all data frames will have this number of columns. Ifcolsis 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 = 0Lor a range likecols = c(0L, 10L).- any_na
Whether
NAvalues should be allowed.
Examples
any_data.table(rows = 3L, cols = 3L) %>% show_example()
#> ...1 ...2 ...3
#> <hms> <POSc> <num>
#> 1: 16:19:25.395917 2296-10-19 12:52:29 -369516495
#> 2: 11:58:19.761905 2309-01-10 05:36:54 63147082
#> 3: 15:24:00.454024 2972-02-20 05:17:32 558617252