Skip to content

Commit

Permalink
pass cores to helpers
Browse files Browse the repository at this point in the history
  • Loading branch information
nick-robo committed Oct 4, 2023
1 parent 20b2d09 commit 4bb16e9
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions R/run_scfeatures.R
Original file line number Diff line number Diff line change
Expand Up @@ -935,9 +935,9 @@ run_L_function <- function(data, type = "spatial_p", ncores = 1) {
))
return(NULL)
} else if (type == "spatial_p") {
X <- helper_L_stat_sp(data)
X <- helper_L_stat_sp(data, ncores)
} else if (type == "spatial_t") {
X <- helper_L_stat_st(data)
X <- helper_L_stat_st(data, ncores)
} else {
cli::cli_abort(c(
"Parameter {.var type} must be 'scrna', 'spatial_p' or 'spatial_t'",
Expand Down Expand Up @@ -1004,9 +1004,9 @@ run_celltype_interaction <- function(data, type = "spatial_p", ncores = 1) {
))
return(NULL)
} else if (type == "spatial_p") {
X <- helper_celltype_interaction_sp(data)
X <- helper_celltype_interaction_sp(data, ncores)
} else if (type == "spatial_t") {
X <- helper_celltype_interaction_st(data)
X <- helper_celltype_interaction_st(data, ncores)
}

X <- as.data.frame(X)
Expand Down Expand Up @@ -1073,7 +1073,7 @@ run_Morans_I <- function(data, type = "spatial_p", ncores = 1) {
))
return(NULL)
} else if (type %in% c("spatial_p", "spatial_t")) {
X <- helper_moran(data, num_top_gene = NULL, ncores = 1)
X <- helper_moran(data, num_top_gene = NULL, ncores)
} else {
cli::cli_abort(c(
"Parameter {.var type} must be 'scrna', 'spatial_p' or 'spatial_t'",
Expand Down

0 comments on commit 4bb16e9

Please sign in to comment.