Skip to content

Commit f73576c

Browse files
committed
Update S3 methods export
1 parent 0bb86be commit f73576c

File tree

3 files changed

+10
-3
lines changed

3 files changed

+10
-3
lines changed

NAMESPACE

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -62,6 +62,8 @@ S3method(as.labelled,labelled)
6262
S3method(as.labelled,list)
6363
S3method(as.logical,labelled)
6464
S3method(as.numeric,labelled)
65+
S3method(build_compare,default)
66+
S3method(build_compare,numeric)
6567
S3method(c,labelled)
6668
S3method(calculate,data.frame)
6769
S3method(calculate,list)
@@ -113,6 +115,7 @@ S3method(make_labels_from_names,list)
113115
S3method(make_subheadings,default)
114116
S3method(make_subheadings,etable)
115117
S3method(mean,data.frame)
118+
S3method(median,data.frame)
116119
S3method(merge,etable)
117120
S3method(n_diff,data.frame)
118121
S3method(n_diff,data.table)
@@ -679,3 +682,7 @@ import(matrixStats)
679682
import(stats)
680683
import(utils)
681684
importFrom(data.table,data.table)
685+
importFrom(htmlTable,htmlTable)
686+
importFrom(htmlTable,htmlTableWidget)
687+
importFrom(htmlTable,htmlTableWidgetOutput)
688+
importFrom(htmlTable,interactiveTable)

R/S3_methods.R

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,8 @@ mtfrm.labelled <- function(x) {
1616
as.data.frame.labelled = function(x, ..., nm = paste(deparse(substitute(x), width.cutoff = 500L)) ){
1717
if(length(class(x))>1){
1818
# because we can have labelled matrices or factors with variable label
19-
NextMethod("as.data.frame", ..., nm = nm, stringsAsFactors = FALSE)
20-
19+
# NextMethod("as.data.frame", ..., nm = nm, stringsAsFactors = FALSE)
20+
as.data.frame.vector(x, ..., nm = nm, stringsAsFactors = FALSE)
2121
} else {
2222
# this branch for other packages where "labelled' is single class rather than c("labelled", "numeric") etc.
2323

R/sum.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -119,7 +119,7 @@ sd_col=function(..., na.rm = TRUE){
119119

120120
################################################
121121

122-
# @export
122+
#' @exportS3Method
123123
median.data.frame = function(x, ...) stats::median(as.matrix(x), ...)
124124

125125
#' @export

0 commit comments

Comments
 (0)