diff --git a/NAMESPACE b/NAMESPACE index 6f839e8e..4c49ab40 100644 --- a/NAMESPACE +++ b/NAMESPACE @@ -745,6 +745,7 @@ importFrom("stats", "as.formula", "complete.cases", "cor", "cov", "var", "pt", S3method('[[', GRP_df) S3method('[<-', GRP_df) S3method('[[<-', GRP_df) + S3method('names<-', GRP_df) S3method('[', indexed_series) S3method(Math, indexed_series) S3method(Ops, indexed_series) diff --git a/R/GRP.R b/R/GRP.R index ce737aba..f3eed2b1 100644 --- a/R/GRP.R +++ b/R/GRP.R @@ -502,6 +502,7 @@ print.invisible <- function(x, ...) cat("") `[[.GRP_df` <- function(x, ...) UseMethod("[[", fungroup(x)) # function(x, ..., exact = TRUE) .subset2(x, ..., exact = exact) `[<-.GRP_df` <- function(x, ..., value) UseMethod("[<-", fungroup(x)) `[[<-.GRP_df` <- function(x, ..., value) UseMethod("[[<-", fungroup(x)) +`names<-.GRP_df` <- function(x, value) `oldClass<-`(`names<-`(unclass(x), value), oldClass(x)) # Produce errors... # print_GRP_df_core <- function(x) {