Skip to content

Commit

Permalink
Update test_features.R
Browse files Browse the repository at this point in the history
  • Loading branch information
michbur authored Jun 19, 2024
1 parent 63f717d commit cb562f5
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions R/test_features.R
Original file line number Diff line number Diff line change
Expand Up @@ -105,10 +105,10 @@ test_features <- function(target, features, criterion = "ig", adjust = "BH",
}


feature_size <- if ("simple_triplet_matrix" %in% class(features)) {
feature_size <- if (inherits(features, "simple_triplet_matrix")) {
slam::col_sums(features)
} else {
if ("dgCMatrix" %in% class(features)) {
if (inherits(features, "dgCMatrix")) {
Matrix::colSums(features)
} else {
colSums(features)
Expand Down

0 comments on commit cb562f5

Please sign in to comment.