-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added test for gs_score function and bump version.
- Loading branch information
Showing
7 changed files
with
42 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
Package: smartid | ||
Title: Scoring and Marker Selection Method Based on Modified TF-IDF | ||
Version: 0.99.1 | ||
Version: 0.99.2 | ||
Authors@R: | ||
person("Jinjin", "Chen", email = "[email protected]", role = c("aut", "cre"), | ||
comment = c(ORCID = "0000-0001-7923-5723")) | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,3 +5,7 @@ | |
# smartid 0.99.1 | ||
|
||
* Ready for submission to Bioconductor. | ||
|
||
# smartid 0.99.2 | ||
|
||
* Added test for `gs_score` function. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
test_that("gs_score works", { | ||
## sim data | ||
set.seed(123) | ||
data <- matrix(rnorm(100), 10, dimnames = list(seq_len(10))) | ||
|
||
se <- SummarizedExperiment::SummarizedExperiment( | ||
assays = list(counts = data) | ||
) | ||
|
||
## test matrix | ||
res <- gs_score(data, features = seq_len(3)) | ||
expect_type(res, "double") | ||
|
||
## test matrix, feature list | ||
res <- gs_score(data, features = list(a = seq_len(3), b = seq_len(5))) | ||
expect_type(res, "list") | ||
|
||
## test se | ||
res <- gs_score(se, features = seq_len(3), slot = "counts") | ||
expect_type(res$score, "double") | ||
|
||
## test se, feature list | ||
res <- gs_score(se, features = list(a = seq_len(3), b = seq_len(5)), | ||
slot = "counts") | ||
expect_type(colnames(res@colData), "character") | ||
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters