dts_complete | R Documentation |
Completes a data time series
dts_complete(
x,
dtt = "DateTime",
colname = dts_colnames(x),
from = min(x[[dtt]]),
to = max(x[[dtt]]),
floor = TRUE,
unique = TRUE,
sort = TRUE,
units = dttr2::dtt_units(x[[dtt]]),
.dts_fun = mean,
...
)
x |
A date/time vector. |
dtt |
A string specifying the column with the Date or POSIXct values. |
colname |
A character vector specifying the column(s) with the other values. |
from |
A date/time scalar of the start. |
to |
A date/time scalar of the end. |
floor |
A flag indicating whether to floor the values. |
unique |
A flag specifying whether to only return unique values. |
sort |
A flag specifying whether to sort the vector. |
units |
A string of the time units. The possible values are "secs", "minutes", "hours", "days" or "weeks". |
.dts_fun |
A function which returns a scalar. |
... |
Unused. |
The completed data time series.
dts_complete(dts_data[c(1,3),])
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.