diff --git a/tools/spapros/.shed.yml b/tools/spapros/.shed.yml
new file mode 100644
index 00000000000..b492b9b6e0f
--- /dev/null
+++ b/tools/spapros/.shed.yml
@@ -0,0 +1,19 @@
+name: spapros
+owner: iuc
+description: "Select and evaluate probe sets for targeted spatial transcriptomics."
+homepage_url: https://github.com/theislab/spapros
+long_description: |
+ Spapros is a python package that provides a pipeline for probe set selection and evaluation for targeted spatial transcriptomics data.
+remote_repository_url: https://github.com/galaxyproject/tools-iuc/tree/master/tools/spapros/
+type: unrestricted
+categories:
+- Transcriptomics
+- Sequence Analysis
+auto_tool_repositories:
+ name_template: "{{ tool_id }}"
+ description_template: "Wrapper for the spapros tool suite: {{ tool_name }}"
+suite:
+ name: "suite_spapros"
+ description: "Spapros - Probe selection and evaluation"
+ long_description: |
+ Spapros is a python package that provides a pipeline for probe set selection and evaluation for targeted spatial transcriptomics data.
\ No newline at end of file
diff --git a/tools/spapros/evaluation.xml b/tools/spapros/evaluation.xml
new file mode 100644
index 00000000000..522851b0e14
--- /dev/null
+++ b/tools/spapros/evaluation.xml
@@ -0,0 +1,598 @@
+
+ of marker genes with spapros
+
+ macros.xml
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ format == 'png'
+
+
+ format == 'pdf'
+
+
+ format == 'svg'
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/tools/spapros/macros.xml b/tools/spapros/macros.xml
new file mode 100644
index 00000000000..89aeaab129c
--- /dev/null
+++ b/tools/spapros/macros.xml
@@ -0,0 +1,96 @@
+
+ 0.1.5
+ 0
+ 22.05
+
+
+ spapros
+
+
+
+
+
+
+
+
+
+
+ 10.1101/2022.08.16.504115
+ 10.1093/gigascience/giaa102
+
+
+
+
+
+ '$hidden_output' &&
+python '$script_file' >> '$hidden_output' &&
+ls . >> '$hidden_output'
+ ]]>
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ show_log
+
+
+
diff --git a/tools/spapros/selection.xml b/tools/spapros/selection.xml
new file mode 100644
index 00000000000..232ca833077
--- /dev/null
+++ b/tools/spapros/selection.xml
@@ -0,0 +1,541 @@
+
+ of marker genes with spapros
+
+ macros.xml
+
+
+
+
+
+
+ 1 and '' in recognized_celltypes):
+ recognized_celltypes.remove('')
+
+ for c in recognized_celltypes:
+ if c == '':
+ c = 'Unkown'
+ if c not in marker_dict:
+ marker_dict[c] = [g]
+ else:
+ marker_dict[c] = marker_dict[c] + [g]
+
+# Find the maximum length of lists
+max_len = max(len(lst) for lst in marker_dict.values())
+sorted_marker_dict_by_keys = {key: marker_dict[key] for key in sorted(marker_dict.keys())}
+# Fill smaller lists with empty values
+for key, value in sorted_marker_dict_by_keys.items():
+ sorted_marker_dict_by_keys[key] = value + [''] * (max_len - len(value))
+df = pd.DataFrame(sorted_marker_dict_by_keys).T
+df.to_csv('marker.tsv', sep='\t', index=True)
+
+]]>
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ format == 'png'
+
+
+ format == 'pdf'
+
+
+ format == 'svg'
+
+
+ format == 'png'
+
+
+ format == 'pdf'
+
+
+ format == 'svg'
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/tools/spapros/test-data/marker.tsv b/tools/spapros/test-data/marker.tsv
new file mode 100644
index 00000000000..dfd6e1951fd
--- /dev/null
+++ b/tools/spapros/test-data/marker.tsv
@@ -0,0 +1 @@
+CD14+ Monocyte PILRA PSAP CD68 TMEM176B
\ No newline at end of file
diff --git a/tools/spapros/test-data/marker_out_test1.tsv b/tools/spapros/test-data/marker_out_test1.tsv
new file mode 100644
index 00000000000..b0ad9579a1e
--- /dev/null
+++ b/tools/spapros/test-data/marker_out_test1.tsv
@@ -0,0 +1,11 @@
+ 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30
+CD14+ Monocyte FTL FCER1G
+CD19+ B ISG20 LY86
+CD34+ PRSS57 SNHG7
+CD4+/CD25 T Reg SIT1 IL32
+CD4+/CD45RO+ Memory GZMK IL32 CD3E
+CD56+ NK CD7 GNLY
+CD8+ Cytotoxic T CCL5 S100A4 NKG7
+CD8+/CD45RA+ Naive Cytotoxic CD7 CD8A CD8B AES
+Dendritic CD74 LYZ
+Unkown LTB CD247 SERPINB1 RPLP1 TNFRSF13B BLK SPON2 TPD52 RNF138 NUCB2 CD27 AMICA1 BTG1 CD63 HOPX PTPRCAP CPVL JUN RAB3IP SPOCK2 PRF1 GZMA STK17A RPL3 GYPC SOX4 GZMH LINC00402 C9orf142 VIMP DENND2D
diff --git a/tools/spapros/test-data/marker_out_test2.tsv b/tools/spapros/test-data/marker_out_test2.tsv
new file mode 100644
index 00000000000..9f0ec2bcea7
--- /dev/null
+++ b/tools/spapros/test-data/marker_out_test2.tsv
@@ -0,0 +1,10 @@
+ 0 1 2
+CD14+ Monocyte FTL
+CD19+ B ISG20
+CD34+ PRSS57
+CD4+/CD25 T Reg SIT1 IL32
+CD4+/CD45RO+ Memory GZMK IL32 CD3E
+CD56+ NK CD7
+CD8+ Cytotoxic T CCL5
+CD8+/CD45RA+ Naive Cytotoxic CD7
+Dendritic CD74
diff --git a/tools/spapros/test-data/marker_out_test3.tsv b/tools/spapros/test-data/marker_out_test3.tsv
new file mode 100644
index 00000000000..a069363a747
--- /dev/null
+++ b/tools/spapros/test-data/marker_out_test3.tsv
@@ -0,0 +1,4 @@
+ 0 1
+CD34+ PRSS57 SNHG7
+CD56+ NK CD7 CTSW
+Unkown RPL3
diff --git a/tools/spapros/test-data/marker_out_test4.tsv b/tools/spapros/test-data/marker_out_test4.tsv
new file mode 100644
index 00000000000..eb65acd0495
--- /dev/null
+++ b/tools/spapros/test-data/marker_out_test4.tsv
@@ -0,0 +1,11 @@
+ 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30
+CD14+ Monocyte FTL FCER1G
+CD19+ B ISG20 CD79A
+CD34+ PRSS57 SNHG7
+CD4+/CD25 T Reg SIT1 IL32
+CD4+/CD45RO+ Memory GZMK IL32 CD3E
+CD56+ NK CD7 GNLY
+CD8+ Cytotoxic T CCL5 S100A4 NKG7
+CD8+/CD45RA+ Naive Cytotoxic CD7 CD8A CD8B AES
+Dendritic CD74 CST3
+Unkown LTB CD247 SERPINB1 RPLP1 TNFRSF13B BLK SPON2 TPD52 RNF138 NUCB2 CD27 AMICA1 BTG1 CD63 HOPX PTPRCAP CPVL JUN RAB3IP SPOCK2 PRF1 GZMA STK17A RPL3 GYPC SOX4 GZMH LINC00402 C9orf142 VIMP DENND2D
diff --git a/tools/spapros/test-data/marker_out_test5.tsv b/tools/spapros/test-data/marker_out_test5.tsv
new file mode 100644
index 00000000000..b0ad9579a1e
--- /dev/null
+++ b/tools/spapros/test-data/marker_out_test5.tsv
@@ -0,0 +1,11 @@
+ 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30
+CD14+ Monocyte FTL FCER1G
+CD19+ B ISG20 LY86
+CD34+ PRSS57 SNHG7
+CD4+/CD25 T Reg SIT1 IL32
+CD4+/CD45RO+ Memory GZMK IL32 CD3E
+CD56+ NK CD7 GNLY
+CD8+ Cytotoxic T CCL5 S100A4 NKG7
+CD8+/CD45RA+ Naive Cytotoxic CD7 CD8A CD8B AES
+Dendritic CD74 LYZ
+Unkown LTB CD247 SERPINB1 RPLP1 TNFRSF13B BLK SPON2 TPD52 RNF138 NUCB2 CD27 AMICA1 BTG1 CD63 HOPX PTPRCAP CPVL JUN RAB3IP SPOCK2 PRF1 GZMA STK17A RPL3 GYPC SOX4 GZMH LINC00402 C9orf142 VIMP DENND2D
diff --git a/tools/spapros/test-data/tl.rank_genes_groups.newton-cg.pbmc68k_highly_reduced_marker_filtered_1.tsv b/tools/spapros/test-data/tl.rank_genes_groups.newton-cg.pbmc68k_highly_reduced_marker_filtered_1.tsv
new file mode 100644
index 00000000000..62bc0971dcc
--- /dev/null
+++ b/tools/spapros/test-data/tl.rank_genes_groups.newton-cg.pbmc68k_highly_reduced_marker_filtered_1.tsv
@@ -0,0 +1,11 @@
+ 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49
+CD14+ Monocyte PILRA PSAP CD68 TMEM176B FTL NPC2 LST1 FCGR3A FCER1G CEBPB FCN1 SERPINA1 OAZ1 CFD FTH1 HCK AIF1 SAT1 CTSS S100A11 MS4A7 TYROBP COTL1 STXBP2 RP11-290F20.3 S100A4 IFITM2 SPI1 DUSP1 SESN2 IFITM3 MPP1 GALE CORO1B RP11-390E23.6 VIMP RSBN1L-AS1 CHD4 CFP GSTP1 PFN1 FCGRT ADTRP ARHGDIB AMICA1 HLA-DRB5 CST3 GRN HLA-DPA1 SSR3
+CD19+ B TNFRSF13B CD79B SMARCB1 PNOC CCDC50 AL928768.3 BANK1 MS4A1 CD79A ISG20 IGLL5 TNFRSF17 KIAA0125 TPD52 PEBP1 FKBP11 CCDC132 SUB1 POU2AF1 MZB1 PTPRCAP UBE2J1 BLK SPIB DERL3 FAM63B MPHOSPH9 IGJ FCRLA XBP1 NCF1 SSR3 CD52 TSHZ2 PDLIM1 VIMP SSR4 S1PR4 SELL HMGA1 NUCB2 JUN CD27 ARHGDIB GYPC CALR ADTRP BTG1 EXOG RARRES3
+CD34+ PRSS57 C19orf77 SPINK2 RP11-620J15.3 SNHG7 CYTL1 EGFL7 NGFRAP1 SOX4 NFE2 EGR1 RP3-467N11.1 H1FX CDK6 SERPINB1 SPINT2 HMGA1 IL1B NUCB2 RPLP0 IGFBP7 RPLP1 ATXN7L3B RPS3 C1orf228 KIAA0125 RPL3 SYPL1 CD63 LDHB SEPT1 JUN FAM101B PRKCQ-AS1 MATK PEBP1 SELL ITM2A SSR3 SPON2 XBP1 UBE2J1 VIMP GYPC STK17A STMN1 VIM MZB1 HOPX CD99
+CD4+/CD25 T Reg IL32 SPOCK2 ACTG1 CD2 CD3D GPR171 ARHGDIB ACOX1 MAL SIT1 GIMAP4 AES CD52 SEPT1 TMSB10 LAT STMN1 LINC00402 CD27 TSHZ2 S1PR4 CD3E PFN1 CD99 AQP3 PTPRCAP CD3G LY9 LCK CD247 S100A4 CCR7 TTC39C CORO1B MPHOSPH9 FYB RPSA FLT3LG B2M GIMAP7 PRKCQ-AS1 SELL BTG1 CCDC132 GYPC DENND2D LDHB IL7R ITM2A RPLP0
+CD4+/CD45RA+/CD25- Naive T EAF2 GNG7 SSR4 CALR DERL3 MANF IGJ XBP1 ATXN7L3B SSR3 UBE2J1 CD79A MZB1 RP3-467N11.1 TNFRSF17 NCF1 CDK6 SUB1 POU2AF1 AL928768.3 FKBP11 VIMP GYPC JUN CD27 PEBP1 SMARCB1 FLT3LG RPLP1 RPLP0 CCDC50 ISG20 IGLL5 HCST GSTP1 GPX1 CD52 VIM PTPRCAP FCGRT CD74 B2M RPL3 CYTL1 SPINK2 PRSS57 C19orf77 RP11-620J15.3 FAM101B CCDC132
+CD4+/CD45RO+ Memory RNF138 NOSIP IFITM1 LCK RARRES3 ALOX5AP FAM63B RAB3IP GZMK CD3G SEPT1 LDHB SELL CD3D EXOG RPSA CD247 AES CD52 TMSB10 NUCB2 DENND2D RPL3 RPLP1 ACTG1 FYB GIMAP7 CORO1B LY9 CD7 PFN1 RPS3 GYPC CD2 ARHGDIB IL32 RPLP0 CD99 CD3E GIMAP4 HCST B2M LAT ISG20 ITM2A FKBP11 SERPINB1 STK17A CCR7 PTPRCAP
+CD56+ NK CST7 SPON2 HOPX GNLY NKG7 CTSW KLRC2 CD7 MATK PCIF1 CLIC3 FGFBP2 SYPL1 GZMB C9orf142 PRF1 CD247 HCST GZMA GZMH STMN1 ALOX5AP CD63 CD99 IGFBP7 GZMM CCL5 B2M DENND2D GIMAP7 RARRES3 SIT1 IFITM1 PFN1 EXOG XBP1 IFITM2 GIMAP4 VIMP STK17A LCK GZMK SEPT1 SSR3 CD8A CD3G SPOCK2 RPS3 LDHB IL32
+CD8+ Cytotoxic T FAM101B ADTRP GZMK HCST LAT EGR1 CD8B CCL5 RPL3 LINC00402 FGFBP2 GZMM RPS3 CD3E GYPC DENND2D C9orf142 GZMA SEPT1 JUN FYB CD8A SELL ALOX5AP CD3G STK17A AQP3 C1orf228 CD3D HOPX NKG7 CD2 NGFRAP1 RPLP1 RPSA CCR7 IL7R SPON2 PRF1 RARRES3 PRKCQ-AS1 FKBP11 MANF CTSW GNLY CD27 LDHB MAL LTB RPLP0
+CD8+/CD45RA+ Naive Cytotoxic RP11-291B21.2 CD8A CD8B RSBN1L-AS1 GIMAP5 GZMM GALE CCR7 STK17A RAB3IP GZMH GIMAP7 CD3E C1orf228 LCK CCL5 PEBP1 CD27 GYPC LDHB RNF34 CD99 CD3G PFN1 IL7R CD2 C9orf142 TMSB10 NGFRAP1 S1PR4 ITM2A CD7 RPS3 IL32 FYB IFITM1 CD52 LAT GIMAP4 MAL STMN1 NOSIP RARRES3 SPOCK2 ACTG1 PRF1 CD3D RPLP1 SELL GZMA
+Dendritic HLA-DQB1 CST3 HLA-DRB1 HLA-DQA2 HLA-DQA1 LYZ HLA-DPB1 HLA-DPA1 HLA-DMA HLA-DRA VIM CD74 ALDH2 FCER1A GPX1 HLA-DRB5 LGALS2 MNDA FCGRT GRN HLA-DMB FOS CPVL CLEC10A AMICA1 CFP LY86 GSTP1 RP11-473M20.7 IL1B GSN SPINT2 CCDC163P IGFBP7 EXOG DUSP1 CD63 COTL1 FTH1 SPI1 TYROBP SPIB S100A11 OAZ1 CTSS CCDC50 AIF1 SERPINB1 TMSB10 PCIF1
diff --git a/tools/spapros/test-data/tl.rank_genes_groups.newton-cg.pbmc68k_reduced_240cells.h5ad b/tools/spapros/test-data/tl.rank_genes_groups.newton-cg.pbmc68k_reduced_240cells.h5ad
new file mode 100644
index 00000000000..39b2514a6b9
Binary files /dev/null and b/tools/spapros/test-data/tl.rank_genes_groups.newton-cg.pbmc68k_reduced_240cells.h5ad differ