Skip to content

Commit 1006fa9

Browse files
committed
Prefix functions with their packages
1 parent f1a180b commit 1006fa9

File tree

1 file changed

+16
-16
lines changed

1 file changed

+16
-16
lines changed

R/tm_missing_data.R

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1185,13 +1185,13 @@ srv_missing_data <- function(id,
11851185
)
11861186
tile <- within(ANL_q,
11871187
{
1188-
by_variable_plot <- ggplot(ANL, aes(group_var_name, name)) +
1189-
geom_tile(aes(fill = column)) +
1190-
geom_text(aes(label = scales::percent(perc)),
1191-
data = . %>% filter(perc > 0), color = "white"
1188+
by_variable_plot <- ggplo2::ggplot(ANL, ggplo2::aes(group_var_name, name)) +
1189+
ggplo2::geom_tile(ggplo2::aes(fill = column)) +
1190+
ggplo2::geom_text(ggplo2::aes(label = scales::percent(perc)),
1191+
data = . %>% dplyr::filter(perc > 0), color = "white"
11921192
) +
1193-
scale_x_discrete(expand = expansion()) +
1194-
scale_fill_gradient(high = "#ff2951ff", low = "grey90", labels = labels) +
1193+
ggplo2::scale_x_discrete(expand = ggplo2::expansion()) +
1194+
ggplo2::scale_fill_gradient(high = "#ff2951ff", low = "grey90", labels = labels) +
11951195
labs +
11961196
ggthemes
11971197
},
@@ -1211,13 +1211,13 @@ srv_missing_data <- function(id,
12111211
keep_columns <- intersect(c(keys, group_var), colnames(ANL))
12121212
labels <- vapply(qenv$ANL, attr, which = "label", FUN.VALUE = character(1L))
12131213
ANL <- ANL %>%
1214-
filter(group_var_name %in% group_vals) %>%
1215-
pivot_longer(-keep_columns, values_transform = is.na) %>%
1216-
summarise(
1214+
dplyr::filter(group_var_name %in% group_vals) %>%
1215+
dplyr::pivot_longer(-keep_columns, values_transform = is.na) %>%
1216+
dplyr::summarise(
12171217
.by = c(group_var_name, name),
12181218
value = sum(value), perc = value / n()
12191219
) %>%
1220-
mutate(label = labels[name])
1220+
dplyr::mutate(label = labels[name])
12211221
},
12221222
keys = join_keys(qenv) |> unlist() |> unique(),
12231223
group_var_name = as.name(group_var),
@@ -1227,13 +1227,13 @@ srv_missing_data <- function(id,
12271227

12281228
tile <- within(ANL_q,
12291229
{
1230-
by_variable_plot <- ggplot(ANL, aes(group_var_name, label)) +
1231-
geom_tile(aes(fill = column)) +
1232-
geom_text(aes(label = scales::percent(perc)),
1233-
data = . %>% filter(perc > 0), color = "white"
1230+
by_variable_plot <- ggplo2::ggplot(ANL, ggplo2::aes(group_var_name, label)) +
1231+
ggplo2::geom_tile(ggplo2::aes(fill = column)) +
1232+
ggplo2::geom_text(ggplo2::aes(label = scales::percent(perc)),
1233+
data = . %>% dplyr::filter(perc > 0), color = "white"
12341234
) +
1235-
scale_x_discrete(expand = expansion()) +
1236-
scale_fill_gradient(high = "#ff2951ff", low = "grey90", labels = labels) +
1235+
ggplo2::scale_x_discrete(expand = ggplo2::expansion()) +
1236+
ggplo2::scale_fill_gradient(high = "#ff2951ff", low = "grey90", labels = labels) +
12371237
labs +
12381238
ggthemes
12391239
},

0 commit comments

Comments
 (0)