Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

87 remove datasets - decrease package size #396

Merged
merged 2 commits into from
Dec 13, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions R/adtteSpec.R
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
#' @examples
#' library(dplyr)
#' mae <- hermes::multi_assay_experiment
#' adtte <- teal.modules.hermes::rADTTE %>%
#' adtte <- teal.data::rADTTE %>%
#' dplyr::mutate(CNSR = as.logical(CNSR))
#'
#' new_adtte <- h_km_mae_to_adtte(
Expand Down Expand Up @@ -218,7 +218,7 @@ adtteSpecInput <- function(inputId, # nolint
#' data <- teal_data()
#' data <- within(data, {
#' ADSL <- teal.data::rADSL
#' ADTTE <- teal.modules.hermes::rADTTE %>%
#' ADTTE <- teal.data::rADTTE %>%
#' dplyr::mutate(is_event = .data$CNSR == 0)
#' MAE <- hermes::multi_assay_experiment
#' })
Expand Down
12 changes: 0 additions & 12 deletions R/data.R

This file was deleted.

4 changes: 2 additions & 2 deletions R/forestplot.R
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
#'
#' data <- teal_data()
#' data <- within(data, {
#' ADTTE <- teal.modules.hermes::rADTTE %>%
#' ADTTE <- teal.data::rADTTE %>%
#' dplyr::mutate(is_event = .data$CNSR == 0)
#' MAE <- hermes::multi_assay_experiment
#' })
Expand Down Expand Up @@ -307,7 +307,7 @@ srv_g_forest_tte <- function(id,
sample_tm_g_forest_tte <- function(.test = FALSE) { # nolint
data <- teal_data()
data <- within(data, {
ADTTE <- teal.modules.hermes::rADTTE %>% # nolint
ADTTE <- teal.data::rADTTE %>% # nolint
dplyr::mutate(is_event = .data$CNSR == 0)
MAE <- hermes::multi_assay_experiment # nolint
})
Expand Down
4 changes: 2 additions & 2 deletions R/km.R
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
#'
#' data <- teal_data()
#' data <- within(data, {
#' ADTTE <- teal.modules.hermes::rADTTE %>%
#' ADTTE <- teal.data::rADTTE %>%
#' dplyr::mutate(is_event = .data$CNSR == 0)
#' MAE <- hermes::multi_assay_experiment
#' })
Expand Down Expand Up @@ -303,7 +303,7 @@ srv_g_km <- function(id,
sample_tm_g_km <- function(.test = FALSE) { # nolint
data <- teal_data()
data <- within(data, {
ADTTE <- teal.modules.hermes::rADTTE %>% # nolint
ADTTE <- teal.data::rADTTE %>% # nolint
dplyr::mutate(is_event = .data$CNSR == 0)
MAE <- hermes::multi_assay_experiment # nolint
})
Expand Down
5 changes: 0 additions & 5 deletions data-raw/data.R

This file was deleted.

Binary file removed data/rADTTE.rda
Binary file not shown.
2 changes: 1 addition & 1 deletion man/adtteSpecServer.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion man/h_km_mae_to_adtte.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

20 changes: 0 additions & 20 deletions man/rADTTE.Rd

This file was deleted.

2 changes: 1 addition & 1 deletion man/tm_g_forest_tte.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion man/tm_g_km.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions tests/testthat/adtteSpec/app.R
Original file line number Diff line number Diff line change
Expand Up @@ -65,14 +65,14 @@ server <- function(id,
}

my_app <- function() {
adtte <- teal.modules.hermes::rADTTE %>%
adtte <- teal.data::rADTTE %>%
dplyr::mutate(is_event = (.data$CNSR == 0))

data <- teal_data(
ADTTE = adtte,
MAE = hermes::multi_assay_experiment,
code =
"adtte <- teal.modules.hermes::rADTTE %>%
"adtte <- teal.data::rADTTE %>%
dplyr::mutate(is_event = (.data$CNSR == 0))"
)

Expand Down
12 changes: 6 additions & 6 deletions tests/testthat/test-adtteSpec.R
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

test_that("h_km_mae_to_adtte function works as expected with a single gene", {
mae <- hermes::multi_assay_experiment
adtte <- teal.modules.hermes::rADTTE %>%
adtte <- teal.data::rADTTE %>%
dplyr::mutate(CNSR = as.logical(.data$CNSR))

result <- h_km_mae_to_adtte(
Expand All @@ -19,7 +19,7 @@ test_that("h_km_mae_to_adtte function also works when some ID variables are fact
mae <- hermes::multi_assay_experiment
SummarizedExperiment::colData(mae)$USUBJID <- # nolint
factor(SummarizedExperiment::colData(mae)$USUBJID)
adtte <- teal.modules.hermes::rADTTE %>%
adtte <- teal.data::rADTTE %>%
dplyr::mutate(USUBJID = factor(USUBJID))

result <- h_km_mae_to_adtte(
Expand All @@ -34,7 +34,7 @@ test_that("h_km_mae_to_adtte function also works when some ID variables are fact

test_that("h_km_mae_to_adtte function works as expected with multiple genes", {
mae <- hermes::multi_assay_experiment
adtte <- teal.modules.hermes::rADTTE %>%
adtte <- teal.data::rADTTE %>%
dplyr::mutate(CNSR = as.logical(.data$CNSR))

result <- h_km_mae_to_adtte(
Expand All @@ -49,7 +49,7 @@ test_that("h_km_mae_to_adtte function works as expected with multiple genes", {

test_that("h_km_mae_to_adtte function works as expected with a gene signature", {
mae <- hermes::multi_assay_experiment
adtte <- teal.modules.hermes::rADTTE %>%
adtte <- teal.data::rADTTE %>%
dplyr::mutate(CNSR = as.logical(.data$CNSR))

result <- h_km_mae_to_adtte(
Expand All @@ -65,7 +65,7 @@ test_that("h_km_mae_to_adtte function works as expected with a gene signature",

test_that("h_km_mae_to_adtte fails as expected with invalid settings", {
mae <- hermes::multi_assay_experiment
adtte <- teal.modules.hermes::rADTTE %>%
adtte <- teal.data::rADTTE %>%
dplyr::mutate(CNSR = as.logical(.data$CNSR))
good_adtte <- adtte

Expand Down Expand Up @@ -97,7 +97,7 @@ test_that("h_km_mae_to_adtte fails as expected with invalid settings", {

test_that("h_km_mae_to_adtte warns when patients are not in ADTTE and therefore removed", {
mae <- hermes::multi_assay_experiment
adtte <- teal.modules.hermes::rADTTE %>%
adtte <- teal.data::rADTTE %>%
dplyr::mutate(CNSR = as.logical(.data$CNSR))

# Example with no matched patient IDs.
Expand Down
Loading