Skip to content

Commit 5e9bb5f

Browse files
committed
update dplyr methods
- comments in slice example are preserved
1 parent ce574bd commit 5e9bb5f

26 files changed

+2420
-1635
lines changed

NAMESPACE

Lines changed: 3 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -30,39 +30,21 @@ S3method(select,SummarizedExperiment)
3030
S3method(separate,SummarizedExperiment)
3131
S3method(slice,SummarizedExperiment)
3232
S3method(summarise,SummarizedExperiment)
33+
S3method(summarize,SummarizedExperiment)
3334
S3method(tbl_format_header,tidySummarizedExperiment)
3435
S3method(tidy,RangedSummarizedExperiment)
3536
S3method(tidy,SummarizedExperiment)
3637
S3method(unite,SummarizedExperiment)
3738
S3method(unnest,tidySummarizedExperiment_nested)
3839
export("%>%")
39-
export()
4040
export(as_tibble)
41-
export(bind_rows)
42-
export(count)
43-
export(distinct)
4441
export(extract)
45-
export(filter)
46-
export(full_join)
4742
export(ggplot)
48-
export(group_by)
49-
export(inner_join)
50-
export(left_join)
51-
export(mutate)
5243
export(nest)
5344
export(pivot_longer)
5445
export(pivot_wider)
5546
export(plot_ly)
56-
export(pull)
57-
export(rename)
58-
export(right_join)
59-
export(rowwise)
60-
export(sample_frac)
61-
export(sample_n)
62-
export(select)
6347
export(separate)
64-
export(slice)
65-
export(summarise)
6648
export(tbl_format_header)
6749
export(tidy)
6850
export(unite)
@@ -105,6 +87,7 @@ importFrom(dplyr,select)
10587
importFrom(dplyr,select_if)
10688
importFrom(dplyr,slice)
10789
importFrom(dplyr,summarise)
90+
importFrom(dplyr,summarize)
10891
importFrom(dplyr,vars)
10992
importFrom(ellipsis,check_dots_unnamed)
11093
importFrom(ellipsis,check_dots_used)
@@ -166,5 +149,6 @@ importFrom(tidyselect,eval_select)
166149
importFrom(tidyselect,one_of)
167150
importFrom(ttservice,bind_cols)
168151
importFrom(ttservice,bind_rows)
152+
importFrom(utils,packageDescription)
169153
importFrom(utils,tail)
170154
importFrom(vctrs,new_data_frame)

R/attach.R

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
core <- c("dplyr", "tidyr", "ttservice", "ggplot2")
2+
3+
core_unloaded <- function() {
4+
search <- paste0("package:", core)
5+
core[!search %in% search()]
6+
}
7+
8+
# Attach the package from the same library it was loaded from before.
9+
# [source: https://github.com/tidy-biology/tidyverse/issues/171]
10+
same_library <- function(pkg) {
11+
loc <- if (pkg %in% loadedNamespaces())
12+
dirname(getNamespaceInfo(pkg, "path"))
13+
library(pkg, lib.loc=loc, character.only=TRUE, warn.conflicts=FALSE)
14+
}
15+
16+
tidyverse_attach <- function() {
17+
to_load <- core_unloaded()
18+
19+
suppressPackageStartupMessages(
20+
lapply(to_load, same_library))
21+
22+
invisible(to_load)
23+
}

0 commit comments

Comments
 (0)