key_update: Change/update key variables for a given tbl_ts
Description
Change/update key variables for a given tbl_ts
Usage
key_update(.data, ..., validate = TRUE)
Arguments
.data
A tbl_ts.
...
Expressions used to construct the key:
unspecified: drop every single variable from the old key.
| and , for nesting and crossing factors.
validate
TRUE suggests to verify that each key or each combination
of key variables lead to unique time indices (i.e. a valid tsibble). It will
also make sure that the nested variables are arranged from lower level to
higher, if nested variables are passed to key. If you are sure that it's a
valid input, specify FALSE to skip the checks.