has_gaps | R Documentation |
Does a tsibble have implicit gaps in time?
has_gaps(.data, .full = FALSE, .name = ".gaps", .start = NULL, .end = NULL)
.data |
A tsibble. |
.full |
|
.name |
Strings to name new columns. |
.start , .end |
Set custom starting/ending time that allows to expand the existing time spans. |
A tibble contains "key" variables and new column .gaps
of TRUE
/FALSE
.
Other implicit gaps handling:
count_gaps()
,
fill_gaps()
,
scan_gaps()
harvest <- tsibble(
year = c(2010, 2011, 2013, 2011, 2012, 2013),
fruit = rep(c("kiwi", "cherry"), each = 3),
kilo = sample(1:10, size = 6),
key = fruit, index = year
)
has_gaps(harvest)
has_gaps(harvest, .full = TRUE)
has_gaps(harvest, .full = start())
has_gaps(harvest, .full = end())
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.