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

Gdr 2399 #135

Merged
merged 3 commits into from
Feb 6, 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 DESCRIPTION
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@ Type: Package
Package: gDRcore
Title: Processing functions and interface to process and analyze drug
dose-response data
Version: 1.1.6
Date: 2024-02-05
Version: 1.1.7
Date: 2024-02-06
Authors@R: c(
person("Bartosz", "Czech", , "[email protected]", role = "aut"),
person("Arkadiusz", "Gladki", role=c("cre", "aut"), email="[email protected]"),
Expand Down
3 changes: 3 additions & 0 deletions NEWS.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
## 1.1.7 (2024-02-06)
- fix bug with converting standardize MAE into raw data

## 1.1.6 (2024-02-05)
- add vignette for a data model

Expand Down
3 changes: 2 additions & 1 deletion R/runDrugResponseProcessingPipeline.R
Original file line number Diff line number Diff line change
Expand Up @@ -204,7 +204,7 @@ runDrugResponseProcessingPipeline <- function(x,
selected_experiments = NULL) {

checkmate::assert_multi_class(x, c("data.table", "MultiAssayExperiment"))
if (inherits(x, "data.table")) {
if (data.table::is.data.table(x)) {
checkmate::assert_true(any(
gDRutils::get_env_identifiers("untreated_tag") %in%
x[[gDRutils::get_env_identifiers("drug")]]
Expand Down Expand Up @@ -247,6 +247,7 @@ runDrugResponseProcessingPipeline <- function(x,
# when running pipeline with x = MAE the identifiers from MAE's metadata
# should be restored
if (inherits(x, "MultiAssayExperiment")) {
x <- gDRutils::standardize_mae(x, use_default = FALSE)
m_idfs <- S4Vectors::metadata(x[[1]])[["identifiers"]]
for (idx in seq_along(m_idfs)) {
gDRutils::set_env_identifier(names(m_idfs)[idx], m_idfs[[idx]])
Expand Down
4 changes: 4 additions & 0 deletions tests/testthat/test-runDrugResponseProcessingPipeline.R
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,10 @@ test_that("main pipeline functions works as expected", {
x
})

# Clear internal metadata (sessionInfo) to not break the tests
mae_v3$result$`single-agent`@metadata$.internal <- NULL
mae_v4$result$`single-agent`@metadata$.internal <- NULL

expect_identical(mae_v3$result, mae_v4$result)

testthat::expect_error(
Expand Down
Loading