File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -64,6 +64,8 @@ resources:
6464 # The script of your component (required)
6565 - type : r_script
6666 path : script.R
67+ - type : r_script
68+ path : /src/utils/helper_functions.R
6769
6870engines :
6971 # Specifications for the Docker image for this component.
Original file line number Diff line number Diff line change @@ -15,9 +15,12 @@ meta <- list(
1515
1616options(future.globals.maxSize = 25 * 1024 ^ 3 ) # 25 GiB
1717
18+ source(paste0(meta $ resources_dir , " /helper_functions.R" ))
19+
1820cat(" Reading input files\n " )
19- input_adata <- anndata :: read_h5ad(par [[" input" ]])
20-
21+ input_adata <- anndata :: read_h5ad(par [[" input" ]]) | >
22+ subset_nocontrols()
23+
2124cat(" Preparing input Anndata\n " )
2225input_adata $ obs $ batch <- as.factor(input_adata $ obs $ batch )
2326
Original file line number Diff line number Diff line change @@ -68,7 +68,8 @@ resources:
6868 # The script of your component (required)
6969 - type : r_script
7070 path : script.R
71-
71+ - type : r_script
72+ path : /src/utils/helper_functions.R
7273engines :
7374 # Specifications for the Docker image for this component.
7475 - type : docker
Original file line number Diff line number Diff line change @@ -15,9 +15,11 @@ meta <- list(
1515
1616options(future.globals.maxSize = 25 * 1024 ^ 3 ) # 25 GiB
1717
18-
18+ source(paste0(meta $ resources_dir , " /helper_functions.R" ))
19+
1920cat(" Reading input files\n " )
20- input_adata <- anndata :: read_h5ad(par [[" input" ]])
21+ input_adata <- anndata :: read_h5ad(par [[" input" ]]) | >
22+ subset_nocontrols()
2123
2224cat(" Preparing input Anndata\n " )
2325input_adata $ obs $ batch <- as.factor(input_adata $ obs $ batch )
You can’t perform that action at this time.
0 commit comments