Skip to content

Commit 20e15e8

Browse files
committed
added vec_restore() for grouped_ts
1 parent d2c5eb5 commit 20e15e8

File tree

2 files changed

+11
-0
lines changed

2 files changed

+11
-0
lines changed

NAMESPACE

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -164,6 +164,7 @@ S3method(vec_cast,tbl_ts.tbl_ts)
164164
S3method(vec_cast,yearmonth.yearmonth)
165165
S3method(vec_cast,yearquarter.yearquarter)
166166
S3method(vec_cast,yearweek.yearweek)
167+
S3method(vec_proxy,grouped_ts)
167168
S3method(vec_proxy,tbl_ts)
168169
S3method(vec_ptype2,Date.yearmonth)
169170
S3method(vec_ptype2,Date.yearquarter)
@@ -188,6 +189,7 @@ S3method(vec_ptype2,yearweek.yearweek)
188189
S3method(vec_ptype_abbr,yearmonth)
189190
S3method(vec_ptype_abbr,yearquarter)
190191
S3method(vec_ptype_abbr,yearweek)
192+
S3method(vec_restore,grouped_ts)
191193
S3method(vec_restore,tbl_ts)
192194
S3method(year,yearweek)
193195
S3method(yearmonth,"NULL")

R/vctrs-tsibble.R

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -102,3 +102,12 @@ vec_restore.tbl_ts <- function(x, to, ..., n = NULL) {
102102
vec_proxy.tbl_ts <- function(x, ...) {
103103
new_data_frame(x)
104104
}
105+
106+
#' @export
107+
vec_restore.grouped_ts <- function(x, to, ..., n = NULL) {
108+
x <- NextMethod()
109+
vec_restore.tbl_ts(x, to)
110+
}
111+
112+
#' @export
113+
vec_proxy.grouped_ts <- vec_proxy.tbl_ts

0 commit comments

Comments
 (0)