Mercurial > repos > iuc > spapros_evaluation
comparison evaluation.xml @ 0:0c1b0a3b19df draft default tip
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/spapros/ commit aed7fe13fa0ed09d77a31eeecaf3ec3fba7eed3b
| author | iuc |
|---|---|
| date | Mon, 16 Sep 2024 11:37:34 +0000 |
| parents | |
| children |
comparison
equal
deleted
inserted
replaced
| -1:000000000000 | 0:0c1b0a3b19df |
|---|---|
| 1 <tool id="spapros_evaluation" name="Evaluation" version="@TOOL_VERSION@+galaxy@VERSION_SUFFIX@" profile="@profile@"> | |
| 2 <description>of marker genes with spapros</description> | |
| 3 <macros> | |
| 4 <import>macros.xml</import> | |
| 5 </macros> | |
| 6 <expand macro="requirements"> | |
| 7 </expand> | |
| 8 <expand macro="version_command"/> | |
| 9 <command detect_errors="exit_code"><![CDATA[ | |
| 10 @CMD@ | |
| 11 ]]></command> | |
| 12 <configfiles> | |
| 13 <configfile name="script_file"><![CDATA[ | |
| 14 @CMD_imports@ | |
| 15 @CMD_read_inputs@ | |
| 16 | |
| 17 mpl.rcParams['figure.dpi'] = $figure_options.dpi | |
| 18 plt.rcParams["font.size"] = $figure_options.fontsize | |
| 19 | |
| 20 header_probeset='infer' | |
| 21 #if $header_probeset == 'not_included': | |
| 22 header_probeset=None | |
| 23 #end if | |
| 24 | |
| 25 ## Probe set generation | |
| 26 probeset = pd.read_csv('$probeset', sep='\t', index_col=0, header=header_probeset) | |
| 27 probeset = [x for x in probeset.values.flatten().tolist() if not pd.isna(x)] | |
| 28 | |
| 29 ## Reference set generation | |
| 30 methods_pre="#echo ','.join(["%s" % $s for $i, $s in enumerate($methods_reference)])#" | |
| 31 methods=methods_pre.split(',') | |
| 32 | |
| 33 reference_sets = sp.se.select_reference_probesets( | |
| 34 adata, | |
| 35 n=$nreference, | |
| 36 #if $genes_key != '': | |
| 37 genes_key='$genes_key', | |
| 38 #else: | |
| 39 genes_key=None, | |
| 40 #end if | |
| 41 #if $obs_key != '': | |
| 42 obs_key='$obs_key', | |
| 43 #end if | |
| 44 #if $seeds != '': | |
| 45 seeds=[$seeds], | |
| 46 #end if | |
| 47 methods=methods, | |
| 48 verbosity=0 | |
| 49 ) | |
| 50 | |
| 51 ## Parameter setting | |
| 52 | |
| 53 custom_params = { | |
| 54 'data': { | |
| 55 'name': '$probeset_name', | |
| 56 'celltype_key': '$celltype_key' | |
| 57 }, | |
| 58 'metrics': { | |
| 59 #if $method.method == 'plot_summary' or $method.method == 'plot_cluster_similarity': | |
| 60 'cluster_similarity': { | |
| 61 'ns': [$method.ns_start, $method.ns_end], | |
| 62 'AUC_borders': [#echo ",".join(["[%s, %s]" % ($s.auc_borders_start, $s.auc_borders_end) for $i, $s in enumerate($method.series_auc_borders)])#] | |
| 63 }, | |
| 64 #end if | |
| 65 #if $method.method == 'plot_summary' or $method.method == 'plot_knn_overlap': | |
| 66 'knn_overlap': { | |
| 67 'ks': [#echo ",".join([ "%s" % $s.k for $i, $s in enumerate($method.knn) ])#] | |
| 68 }, | |
| 69 #end if | |
| 70 #if $method.method == 'plot_confusion_matrix': | |
| 71 'forest_clfs': { | |
| 72 'ct_key': '$celltype_key', | |
| 73 #if $method.method == 'plot_summary': | |
| 74 'threshold': $method.forest_clfs_threshold | |
| 75 #end if | |
| 76 }, | |
| 77 #end if | |
| 78 #if $method.method == 'plot_summary': | |
| 79 #if $method.select_marker_corr.use_marker_corr == 'True': | |
| 80 'marker_corr': { | |
| 81 'per_celltype': $method.select_marker_corr.per_celltype, | |
| 82 'per_marker': $method.select_marker_corr.per_marker, | |
| 83 #if $method.select_marker_corr.select_per_celltype_min_mean.use_per_celltype_min_mean == 'True' | |
| 84 'per_celltype_min_mean': $method.select_marker_corr.select_per_celltype_min_mean.per_celltype_min_mean, | |
| 85 #end if | |
| 86 #if $method.select_marker_corr.select_per_marker_min_mean.use_per_marker_min_mean == 'True' | |
| 87 'per_marker_min_mean': $method.select_marker_corr.select_per_marker_min_mean.per_marker_min_mean | |
| 88 #end if | |
| 89 }, | |
| 90 #end if | |
| 91 #end if | |
| 92 #if $method.method == 'plot_marker_corr': | |
| 93 'marker_corr': { | |
| 94 'per_celltype': $method.per_celltype, | |
| 95 'per_marker': $method.per_marker, | |
| 96 #if $method.select_per_celltype_min_mean.use_per_celltype_min_mean == 'True' | |
| 97 'per_celltype_min_mean': $method.select_per_celltype_min_mean.per_celltype_min_mean, | |
| 98 #else: | |
| 99 'per_celltype_min_mean': None, | |
| 100 #end if | |
| 101 #if $method.select_per_marker_min_mean.use_per_marker_min_mean == 'True' | |
| 102 'per_marker_min_mean': $method.select_per_marker_min_mean.per_marker_min_mean | |
| 103 #else: | |
| 104 'per_marker_min_mean': None | |
| 105 #end if | |
| 106 }, | |
| 107 #end if | |
| 108 #if $method.method == 'plot_summary': | |
| 109 'gene_corr': { | |
| 110 'threshold': $method.gene_corr_threshold | |
| 111 } | |
| 112 #end if | |
| 113 } | |
| 114 } | |
| 115 | |
| 116 ## Setup evaluator | |
| 117 | |
| 118 #if $method.method == 'plot_summary' or $method.method == 'plot_marker_corr': | |
| 119 | |
| 120 header_markerset='infer' | |
| 121 feature_marker=dict() | |
| 122 | |
| 123 #if $method.method == 'plot_summary': | |
| 124 #if $method.select_marker_corr.header_markerset == 'not_included' : | |
| 125 header_markerset=None | |
| 126 #end if | |
| 127 feature_marker = {key: [v for v in list(value.values()) if pd.notna(v)] for key, value in pd.read_csv('$method.select_marker_corr.markerset', sep='\t', index_col=0, header=header_markerset).to_dict(orient='index').items()} | |
| 128 #end if | |
| 129 #if $method.method == 'plot_marker_corr': | |
| 130 #if $method.header_markerset == 'not_included': | |
| 131 header_markerset=None | |
| 132 #end if | |
| 133 feature_marker = {key: [v for v in list(value.values()) if pd.notna(v)] for key, value in pd.read_csv('$method.markerset', sep='\t', index_col=0, header=header_markerset).to_dict(orient='index').items()} | |
| 134 #end if | |
| 135 | |
| 136 #end if | |
| 137 | |
| 138 evaluator = sp.ev.ProbesetEvaluator( | |
| 139 adata, | |
| 140 metrics_params=custom_params, | |
| 141 scheme="full", | |
| 142 verbosity=0, | |
| 143 #if $method.method == 'plot_summary' or $method.method == 'plot_marker_corr': | |
| 144 marker_list=feature_marker, | |
| 145 #end if | |
| 146 results_dir=None | |
| 147 ) | |
| 148 | |
| 149 ## Evaluation reference set | |
| 150 for set_id, df in reference_sets.items(): | |
| 151 gene_set = df[df["selection"]].index.to_list() | |
| 152 evaluator.evaluate_probeset(gene_set, set_id=set_id) | |
| 153 | |
| 154 ## Evaluation probe set | |
| 155 evaluator.evaluate_probeset(probeset, set_id='$probeset_name') | |
| 156 | |
| 157 ## Execution of method ## | |
| 158 | |
| 159 #if $method.method == 'plot_summary': | |
| 160 evaluator.plot_summary( | |
| 161 @CMD_plot@ | |
| 162 ) | |
| 163 #end if | |
| 164 | |
| 165 #if $method.method == 'plot_confusion_matrix': | |
| 166 evaluator.plot_confusion_matrix( | |
| 167 @CMD_plot@ | |
| 168 ) | |
| 169 #end if | |
| 170 | |
| 171 #if $method.method == 'plot_coexpression': | |
| 172 evaluator.plot_coexpression( | |
| 173 @CMD_plot@ | |
| 174 ) | |
| 175 #end if | |
| 176 | |
| 177 #if $method.method == 'plot_cluster_similarity': | |
| 178 evaluator.plot_cluster_similarity( | |
| 179 @CMD_plot@ | |
| 180 ) | |
| 181 #end if | |
| 182 | |
| 183 #if $method.method == 'plot_knn_overlap': | |
| 184 evaluator.plot_knn_overlap( | |
| 185 @CMD_plot@ | |
| 186 ) | |
| 187 #end if | |
| 188 | |
| 189 ## plot_marker_corr does not allow for the show keyword | |
| 190 #if $method.method == 'plot_marker_corr': | |
| 191 evaluator.plot_marker_corr( | |
| 192 #if $method.set_ids != 'all' and $method.set_ids != '': | |
| 193 set_ids=[$method.set_ids], | |
| 194 #end if | |
| 195 save='plot.$format' | |
| 196 ) | |
| 197 #end if | |
| 198 | |
| 199 ]]></configfile> | |
| 200 </configfiles> | |
| 201 <inputs> | |
| 202 <expand macro="inputs_anndata"/> | |
| 203 <expand macro="param_plot_format"/> | |
| 204 <param name="probeset" type="data" format="tabular" label="Probeset tabular file with rows=conditions (e.g., celltypes) and column=features (e.g., genes)"/> | |
| 205 <param name="header_probeset" type="select" optional="false" label="Header in the list of probes?"> | |
| 206 <option value="included">Header incldued</option> | |
| 207 <option value="not_included">Header not included</option> | |
| 208 </param> | |
| 209 <param argument="nreference" type="integer" value="10" min="1" optional="false" label="Number of selected genes to generate a reference set"/> | |
| 210 <param name="methods_reference" type="select" multiple="True" optional="false" label="Select the methods to genereate a reference probeset"> | |
| 211 <option value="random" selected="true">Random</option> | |
| 212 <option value="PCA" selected="false">PCA</option> | |
| 213 <option value="DE" selected="false">Differential expressed features based on wilxocon rank genes test (DE)</option> | |
| 214 <option value="HVG" selected="false">Highly variable features (HVG)</option> | |
| 215 </param> | |
| 216 <param name="genes_key" type="text" optional="true" label="adata.var key for subset of preselected genes to run the selections" help="This is typically highly_variable_genes. Leave empty to not subset genes."/> | |
| 217 <param name="obs_key" type="text" optional="true" label="Column name of adata.obs for which marker scores are calculated" help="Only required for method DE."/> | |
| 218 <param name="seeds" type="text" optional="true" label="List of random integer seeds (comma seperated, e.g., 123,999,22)" help="For each seed, one random gene set is selected if random in methods. Leave it empty to for one random set with a random seed."/> | |
| 219 <param name="probeset_name" type="text" value="probeset" optional="false" label="Name for your probeset that should be displayed in plots"/> | |
| 220 <param name="celltype_key" type="text" value="celltype" optional="false" label="Column name of adata.obs that represents groups of your cells (e.g., celltype)"/> | |
| 221 <conditional name="method"> | |
| 222 <param argument="method" type="select" optional="false" label="Method of spapros"> | |
| 223 <option value="plot_summary">Plot statistic summary, using 'evaluator.plot_summary'</option> | |
| 224 <option value="plot_confusion_matrix">Plot confusion matrix, using 'evaluator.plot_confusion_matrix'</option> | |
| 225 <option value="plot_coexpression">Plot coexpression heatmap, using 'evaluator.plot_coexpression'</option> | |
| 226 <option value="plot_cluster_similarity">Plot cluster similariy, using 'evaluator.plot_cluster_similarity'</option> | |
| 227 <option value="plot_knn_overlap">Plot knn overlap, using 'evaluator.plot_knn_overlap'</option> | |
| 228 <option value="plot_marker_corr">Plot featue marker correlation, using 'evaluator.plot_marker_corr'</option> | |
| 229 </param> | |
| 230 <when value="plot_summary"> | |
| 231 <expand macro="set_ids"/> | |
| 232 <param name="forest_clfs_threshold" type="float" value="0.8" min="0.0" max="1.0" label="Assesses how many cell types (%) can be predicted with an accuracy of at least threshold" help="The metric gives an idea about how many cell types can be identified with high confidence with the given gene set."/> | |
| 233 <param name="gene_corr_threshold" type="float" value="0.8" min="0.0" max="1.0" label="Percentage of features (e.g., genes) that have a maximum correlation of less than threshold with all other features" help="This metric gives an idea about how many features show unique expression profiles in the gene set."/> | |
| 234 <param name="ns_start" type="integer" value="5" min="1" label="The minimum number of leiden clusters clusters" help="Clusterings are calculated with different leiden resolutions to genertate clusterings of n = ns_start to ns_end clusters."/> | |
| 235 <param name="ns_end" type="integer" value="21" min="1" label="The maximum number of leiden clusters clusters" help="Clusterings are calculated with different leiden resolutions to genertate clusterings of n = ns_start to ns_end clusters."/> | |
| 236 <repeat name="series_auc_borders" title="Calculates nmi AUCs over given borders"> | |
| 237 <param name="auc_borders_start" type="integer" value="15" min="1" label="Calculates nmi over n ranges auc_borders_start to auc_borders_end" help="Defined border shouldn't exceed values in nmis."/> | |
| 238 <param name="auc_borders_end" type="integer" value="20" min="1" label="Calculates nmi over n ranges auc_borders_start to auc_borders_end" help="Defined border shouldn't exceed values in nmis."/> | |
| 239 </repeat> | |
| 240 <repeat name="knn" title="Calculate knn graphs for each k"> | |
| 241 <param name="k" type="integer" value="10" min="1" label="Includes nearest neighbors for all k"/> | |
| 242 </repeat> | |
| 243 <conditional name="select_marker_corr"> | |
| 244 <param name="use_marker_corr" type="select" label="Do you want to calculate the correlation between your probeset and marker features?"> | |
| 245 <option value="False">No</option> | |
| 246 <option value="True">Yes</option> | |
| 247 </param> | |
| 248 <when value="True"> | |
| 249 <expand macro="param_markerset"/> | |
| 250 <param name="per_celltype" type="boolean" truevalue="True" falsevalue="False" label="Wether to return columns with per cell type max correlations" checked="true"/> | |
| 251 <param name="per_marker" type="boolean" truevalue="True" falsevalue="False" label="Wether to return columns with per marker max correlations" checked="true"/> | |
| 252 <conditional name="select_per_celltype_min_mean"> | |
| 253 <param name="use_per_celltype_min_mean" type="select" label="Add a column for correlation per cell type that only takes into accounts markers with mean expression > per_celltype_min_mean"> | |
| 254 <option value="False">No</option> | |
| 255 <option value="True">Yes</option> | |
| 256 </param> | |
| 257 <when value="True"> | |
| 258 <param name="per_celltype_min_mean" type="float" value="0.0" min="0.0" label="Set per_celltype_min_mean"/> | |
| 259 </when> | |
| 260 <when value="False"/> | |
| 261 </conditional> | |
| 262 <conditional name="select_per_marker_min_mean"> | |
| 263 <param name="use_per_marker_min_mean" type="select" label="Add a column for correlation per cell type that only takes into accounts markers with mean expression > per_celltype_min_mean"> | |
| 264 <option value="False">No</option> | |
| 265 <option value="True">Yes</option> | |
| 266 </param> | |
| 267 <when value="True"> | |
| 268 <param name="per_marker_min_mean" type="float" value="0.0" min="0.0" label="Set per_marker_min_mean"/> | |
| 269 </when> | |
| 270 <when value="False"/> | |
| 271 </conditional> | |
| 272 </when> | |
| 273 <when value="False"/> | |
| 274 </conditional> | |
| 275 </when> | |
| 276 <when value="plot_confusion_matrix"> | |
| 277 <expand macro="set_ids"/> | |
| 278 </when> | |
| 279 <when value="plot_coexpression"> | |
| 280 <expand macro="set_ids"/> | |
| 281 </when> | |
| 282 <when value="plot_cluster_similarity"> | |
| 283 <expand macro="set_ids"/> | |
| 284 <param name="ns_start" type="integer" value="5" min="1" label="The minimum number of leiden clusters clusters" help="Clusterings are calculated with different leiden resolutions to genertate clusterings of n = ns_start to ns_end clusters."/> | |
| 285 <param name="ns_end" type="integer" value="21" min="1" label="The maximum number of leiden clusters clusters" help="Clusterings are calculated with different leiden resolutions to genertate clusterings of n = ns_start to ns_end clusters."/> | |
| 286 <repeat name="series_auc_borders" title="Calculates nmi AUCs over given borders"> | |
| 287 <param name="auc_borders_start" type="integer" value="15" min="1" label="Calculates nmi over n ranges auc_borders_start to auc_borders_end" help="Defined border shouldn't exceed values in nmis."/> | |
| 288 <param name="auc_borders_end" type="integer" value="20" min="1" label="Calculates nmi over n ranges auc_borders_start to auc_borders_end" help="Defined border shouldn't exceed values in nmis."/> | |
| 289 </repeat> | |
| 290 </when> | |
| 291 <when value="plot_knn_overlap"> | |
| 292 <expand macro="set_ids"/> | |
| 293 <repeat name="knn" title="Calculate knn graphs for each k"> | |
| 294 <param name="k" type="integer" value="10" min="1" label="Includes nearest neighbors for all k"/> | |
| 295 </repeat> | |
| 296 </when> | |
| 297 <when value="plot_marker_corr"> | |
| 298 <expand macro="param_markerset"/> | |
| 299 <expand macro="set_ids"/> | |
| 300 <param name="per_celltype" type="boolean" truevalue="True" falsevalue="False" label="Wether to return columns with per cell type max correlations" checked="true"/> | |
| 301 <param name="per_marker" type="boolean" truevalue="True" falsevalue="False" label="Wether to return columns with per marker max correlations" checked="true"/> | |
| 302 <conditional name="select_per_celltype_min_mean"> | |
| 303 <param name="use_per_celltype_min_mean" type="select" label="Add a column for correlation per cell type that only takes into accounts markers with mean expression > per_celltype_min_mean"> | |
| 304 <option value="False">No</option> | |
| 305 <option value="True">Yes</option> | |
| 306 </param> | |
| 307 <when value="True"> | |
| 308 <param name="per_celltype_min_mean" type="float" value="0.0" min="0.0" label="Set per_celltype_min_mean"/> | |
| 309 </when> | |
| 310 <when value="False"/> | |
| 311 </conditional> | |
| 312 <conditional name="select_per_marker_min_mean"> | |
| 313 <param name="use_per_marker_min_mean" type="select" label="Add a column for correlation per cell type that only takes into accounts markers with mean expression > per_celltype_min_mean"> | |
| 314 <option value="False">No</option> | |
| 315 <option value="True">Yes</option> | |
| 316 </param> | |
| 317 <when value="True"> | |
| 318 <param name="per_marker_min_mean" type="float" value="0.0" min="0.0" label="Set per_marker_min_mean"/> | |
| 319 </when> | |
| 320 <when value="False"/> | |
| 321 </conditional> | |
| 322 </when> | |
| 323 </conditional> | |
| 324 <section name="figure_options" title="Figure Output Options" expanded="false"> | |
| 325 <param argument="dpi" type="integer" value="300" min="1" label="Dpi of figures"/> | |
| 326 <param argument="fontsize" type="integer" value="100" min="1" label="Font size of figures"/> | |
| 327 </section> | |
| 328 <expand macro="inputs_common_advanced"/> | |
| 329 </inputs> | |
| 330 <outputs> | |
| 331 <data name="out_png" format="png" from_work_dir="*.png" label="PNG plot from ${tool.name} (${method.method}) on ${on_string}"> | |
| 332 <filter>format == 'png'</filter> | |
| 333 </data> | |
| 334 <data name="out_pdf" format="pdf" from_work_dir="*.pdf" label="PDF plot from ${tool.name} (${method.method}) on ${on_string}"> | |
| 335 <filter>format == 'pdf'</filter> | |
| 336 </data> | |
| 337 <data name="out_svg" format="svg" from_work_dir="*.svg" label="SVG plot from ${tool.name} (${method.method}) on ${on_string}"> | |
| 338 <filter>format == 'svg'</filter> | |
| 339 </data> | |
| 340 <expand macro="hidden_outputs"/> | |
| 341 </outputs> | |
| 342 <tests> | |
| 343 <test expect_num_outputs="2"> | |
| 344 <param name="adata" value="tl.rank_genes_groups.newton-cg.pbmc68k_reduced_240cells.h5ad"/> | |
| 345 <param name="format" value="png"/> | |
| 346 <param name="probeset" value="tl.rank_genes_groups.newton-cg.pbmc68k_highly_reduced_marker_filtered_1.tsv"/> | |
| 347 <param name="header_probeset" value="included"/> | |
| 348 <param name="nreference" value="30"/> | |
| 349 <param name="methods_reference" value="random,PCA,DE,HVG"/> | |
| 350 <param name="genes_key" value="highly_variable"/> | |
| 351 <param name="obs_key" value="celltype"/> | |
| 352 <param name="seeds" value="123,124"/> | |
| 353 <conditional name="method"> | |
| 354 <param name="method" value="plot_summary"/> | |
| 355 <param name="set_ids" value="all"/> | |
| 356 <param name="forest_clfs_threshold" value="0.8"/> | |
| 357 <param name="gene_corr_threshold" value="0.8"/> | |
| 358 <param name="ns_start" value="5"/> | |
| 359 <param name="ns_end" value="21"/> | |
| 360 <repeat name="series_auc_borders"> | |
| 361 <param name="auc_borders_start" value="7"/> | |
| 362 <param name="auc_borders_end" value="14"/> | |
| 363 </repeat> | |
| 364 <repeat name="series_auc_borders"> | |
| 365 <param name="auc_borders_start" value="15"/> | |
| 366 <param name="auc_borders_end" value="20"/> | |
| 367 </repeat> | |
| 368 <repeat name="knn"> | |
| 369 <param name="k" value="5"/> | |
| 370 </repeat> | |
| 371 <repeat name="knn"> | |
| 372 <param name="k" value="10"/> | |
| 373 </repeat> | |
| 374 <conditional name="select_marker_corr"> | |
| 375 <param name="use_marker_corr" value="True"/> | |
| 376 <param name="markerset" value="marker.tsv"/> | |
| 377 <param name="header_markerset" value="not_included"/> | |
| 378 <param name="per_celltype" value="True"/> | |
| 379 <param name="per_marker" value="True"/> | |
| 380 <conditional name="select_per_celltype_min_mean"> | |
| 381 <param name="use_per_celltype_min_mean" value="False"/> | |
| 382 </conditional> | |
| 383 <conditional name="select_per_marker_min_mean"> | |
| 384 <param name="use_per_marker_min_mean" value="True"/> | |
| 385 <param name="per_marker_min_mean" value="0.025"/> | |
| 386 </conditional> | |
| 387 </conditional> | |
| 388 </conditional> | |
| 389 <param name="show_log" value="true" /> | |
| 390 <output name="hidden_output"> | |
| 391 <assert_contents> | |
| 392 <has_text_matching expression="'name': 'probeset',"/> | |
| 393 <has_text_matching expression="'per_celltype': True,"/> | |
| 394 <has_text_matching expression="'per_marker': True,"/> | |
| 395 <has_text_matching expression="'per_marker_min_mean': 0.025"/> | |
| 396 <has_text_matching expression="evaluator.plot_summary"/> | |
| 397 <has_text_matching expression="save='plot.png',"/> | |
| 398 </assert_contents> | |
| 399 </output> | |
| 400 <output name="out_png"> | |
| 401 <assert_contents> | |
| 402 <has_image_width width="3253" delta="2"/> | |
| 403 <has_image_height height="1446" delta="2"/> | |
| 404 </assert_contents> | |
| 405 </output> | |
| 406 </test> | |
| 407 <test expect_num_outputs="2"> | |
| 408 <param name="adata" value="tl.rank_genes_groups.newton-cg.pbmc68k_reduced_240cells.h5ad"/> | |
| 409 <param name="format" value="png"/> | |
| 410 <param name="probeset" value="tl.rank_genes_groups.newton-cg.pbmc68k_highly_reduced_marker_filtered_1.tsv"/> | |
| 411 <param name="header_probeset" value="included"/> | |
| 412 <param name="nreference" value="30"/> | |
| 413 <param name="methods_reference" value="random,PCA,DE,HVG"/> | |
| 414 <param name="genes_key" value="highly_variable"/> | |
| 415 <param name="obs_key" value="celltype"/> | |
| 416 <param name="seeds" value="123,124"/> | |
| 417 <conditional name="method"> | |
| 418 <param name="method" value="plot_confusion_matrix"/> | |
| 419 <param name="set_ids" value="all"/> | |
| 420 </conditional> | |
| 421 <param name="show_log" value="true" /> | |
| 422 <output name="hidden_output"> | |
| 423 <assert_contents> | |
| 424 <has_text_matching expression="'name': 'probeset',"/> | |
| 425 <has_text_matching expression="'ct_key': 'celltype',"/> | |
| 426 <has_text_matching expression="evaluator.plot_confusion_matrix"/> | |
| 427 <has_text_matching expression="save='plot.png',"/> | |
| 428 </assert_contents> | |
| 429 </output> | |
| 430 <output name="out_png"> | |
| 431 <assert_contents> | |
| 432 <has_image_width width="4560" delta="2"/> | |
| 433 <has_image_height height="1859" delta="2"/> | |
| 434 </assert_contents> | |
| 435 </output> | |
| 436 </test> | |
| 437 <test expect_num_outputs="2"> | |
| 438 <param name="adata" value="tl.rank_genes_groups.newton-cg.pbmc68k_reduced_240cells.h5ad"/> | |
| 439 <param name="format" value="png"/> | |
| 440 <param name="probeset" value="tl.rank_genes_groups.newton-cg.pbmc68k_highly_reduced_marker_filtered_1.tsv"/> | |
| 441 <param name="header_probeset" value="included"/> | |
| 442 <param name="nreference" value="30"/> | |
| 443 <param name="methods_reference" value="random,PCA,DE,HVG"/> | |
| 444 <param name="genes_key" value="highly_variable"/> | |
| 445 <param name="obs_key" value="celltype"/> | |
| 446 <param name="seeds" value="123,124"/> | |
| 447 <conditional name="method"> | |
| 448 <param name="method" value="plot_coexpression"/> | |
| 449 <param name="set_ids" value="all"/> | |
| 450 </conditional> | |
| 451 <param name="show_log" value="true" /> | |
| 452 <output name="hidden_output"> | |
| 453 <assert_contents> | |
| 454 <has_text_matching expression="'name': 'probeset',"/> | |
| 455 <has_text_matching expression="evaluator.plot_coexpression"/> | |
| 456 <has_text_matching expression="save='plot.png',"/> | |
| 457 </assert_contents> | |
| 458 </output> | |
| 459 <output name="out_png"> | |
| 460 <assert_contents> | |
| 461 <has_image_width width="5412" delta="2"/> | |
| 462 <has_image_height height="3463" delta="2"/> | |
| 463 </assert_contents> | |
| 464 </output> | |
| 465 </test> | |
| 466 <test expect_num_outputs="2"> | |
| 467 <param name="adata" value="tl.rank_genes_groups.newton-cg.pbmc68k_reduced_240cells.h5ad"/> | |
| 468 <param name="format" value="png"/> | |
| 469 <param name="probeset" value="tl.rank_genes_groups.newton-cg.pbmc68k_highly_reduced_marker_filtered_1.tsv"/> | |
| 470 <param name="header_probeset" value="included"/> | |
| 471 <param name="nreference" value="30"/> | |
| 472 <param name="methods_reference" value="random,PCA,DE,HVG"/> | |
| 473 <param name="genes_key" value="highly_variable"/> | |
| 474 <param name="obs_key" value="celltype"/> | |
| 475 <param name="seeds" value="123,124"/> | |
| 476 <conditional name="method"> | |
| 477 <param name="method" value="plot_cluster_similarity"/> | |
| 478 <param name="set_ids" value="all"/> | |
| 479 <param name="ns_start" value="3"/> | |
| 480 <param name="ns_end" value="20"/> | |
| 481 <repeat name="series_auc_borders"> | |
| 482 <param name="auc_borders_start" value="7"/> | |
| 483 <param name="auc_borders_end" value="14"/> | |
| 484 </repeat> | |
| 485 <repeat name="series_auc_borders"> | |
| 486 <param name="auc_borders_start" value="15"/> | |
| 487 <param name="auc_borders_end" value="20"/> | |
| 488 </repeat> | |
| 489 </conditional> | |
| 490 <param name="show_log" value="true" /> | |
| 491 <output name="hidden_output"> | |
| 492 <assert_contents> | |
| 493 <has_text_matching expression="'name': 'probeset',"/> | |
| 494 <has_text_matching expression="evaluator.plot_cluster_similarity"/> | |
| 495 <has_text_matching expression="save='plot.png',"/> | |
| 496 </assert_contents> | |
| 497 </output> | |
| 498 <output name="out_png"> | |
| 499 <assert_contents> | |
| 500 <has_image_width width="3223" delta="2"/> | |
| 501 <has_image_height height="1406" delta="2"/> | |
| 502 </assert_contents> | |
| 503 </output> | |
| 504 </test> | |
| 505 <test expect_num_outputs="2"> | |
| 506 <param name="adata" value="tl.rank_genes_groups.newton-cg.pbmc68k_reduced_240cells.h5ad"/> | |
| 507 <param name="format" value="png"/> | |
| 508 <param name="probeset" value="tl.rank_genes_groups.newton-cg.pbmc68k_highly_reduced_marker_filtered_1.tsv"/> | |
| 509 <param name="header_probeset" value="included"/> | |
| 510 <param name="nreference" value="30"/> | |
| 511 <param name="methods_reference" value="random,PCA,DE,HVG"/> | |
| 512 <param name="genes_key" value="highly_variable"/> | |
| 513 <param name="obs_key" value="celltype"/> | |
| 514 <param name="seeds" value="123,124"/> | |
| 515 <conditional name="method"> | |
| 516 <param name="method" value="plot_knn_overlap"/> | |
| 517 <param name="set_ids" value="all"/> | |
| 518 <repeat name="knn"> | |
| 519 <param name="k" value="6"/> | |
| 520 </repeat> | |
| 521 <repeat name="knn"> | |
| 522 <param name="k" value="11"/> | |
| 523 </repeat> | |
| 524 </conditional> | |
| 525 <param name="show_log" value="true" /> | |
| 526 <output name="hidden_output"> | |
| 527 <assert_contents> | |
| 528 <has_text_matching expression="'name': 'probeset',"/> | |
| 529 <has_text_matching expression="evaluator.plot_knn_overlap"/> | |
| 530 <has_text_matching expression="save='plot.png',"/> | |
| 531 </assert_contents> | |
| 532 </output> | |
| 533 <output name="out_png"> | |
| 534 <assert_contents> | |
| 535 <has_image_width width="3223" delta="2"/> | |
| 536 <has_image_height height="1406" delta="2"/> | |
| 537 </assert_contents> | |
| 538 </output> | |
| 539 </test> | |
| 540 <test expect_num_outputs="2"> | |
| 541 <param name="adata" value="tl.rank_genes_groups.newton-cg.pbmc68k_reduced_240cells.h5ad"/> | |
| 542 <param name="format" value="png"/> | |
| 543 <param name="probeset" value="tl.rank_genes_groups.newton-cg.pbmc68k_highly_reduced_marker_filtered_1.tsv"/> | |
| 544 <param name="header_probeset" value="included"/> | |
| 545 <param name="nreference" value="50"/> | |
| 546 <param name="methods_reference" value="random,PCA,DE,HVG"/> | |
| 547 <param name="genes_key" value="highly_variable"/> | |
| 548 <param name="obs_key" value="celltype"/> | |
| 549 <conditional name="method"> | |
| 550 <param name="method" value="plot_marker_corr"/> | |
| 551 <param name="set_ids" value="all"/> | |
| 552 <param name="use_marker_corr" value="True"/> | |
| 553 <param name="markerset" value="marker.tsv"/> | |
| 554 <param name="header_markerset" value="not_included"/> | |
| 555 <param name="per_celltype" value="True"/> | |
| 556 <param name="per_marker" value="True"/> | |
| 557 <conditional name="select_per_celltype_min_mean"> | |
| 558 <param name="use_per_celltype_min_mean" value="False"/> | |
| 559 </conditional> | |
| 560 <conditional name="select_per_marker_min_mean"> | |
| 561 <param name="use_per_marker_min_mean" value="True"/> | |
| 562 <param name="per_marker_min_mean" value="0.025"/> | |
| 563 </conditional> | |
| 564 </conditional> | |
| 565 <param name="show_log" value="true" /> | |
| 566 <output name="hidden_output"> | |
| 567 <assert_contents> | |
| 568 <has_text_matching expression="'name': 'probeset',"/> | |
| 569 <has_text_matching expression="'per_celltype': True,"/> | |
| 570 <has_text_matching expression="'per_marker': True,"/> | |
| 571 <has_text_matching expression="'per_marker_min_mean': 0.025"/> | |
| 572 <has_text_matching expression="evaluator.plot_marker_corr"/> | |
| 573 <has_text_matching expression="save='plot.png'"/> | |
| 574 </assert_contents> | |
| 575 </output> | |
| 576 <output name="out_png"> | |
| 577 <assert_contents> | |
| 578 <has_image_width width="5064" delta="2"/> | |
| 579 <has_image_height height="4554" delta="2"/> | |
| 580 </assert_contents> | |
| 581 </output> | |
| 582 </test> | |
| 583 </tests> | |
| 584 <help><![CDATA[ | |
| 585 Probe set evaluation for single-cell sequencing data using spapros. | |
| 586 ============================================================================================================ | |
| 587 | |
| 588 Spapros is a python package that provides a pipeline for probe set selection and evaluation for targeted spatial transcriptomics data. | |
| 589 | |
| 590 Key Features: | |
| 591 * Select probe sets for spatial transcriptomics which identify cell types of interest, capture general transcriptomic variation, and incorporate prior knowledge | |
| 592 * Evaluate probe sets with an extensive pipeline | |
| 593 | |
| 594 Further documentation can be found here: https://spapros.readthedocs.io/en/latest/index.html. | |
| 595 | |
| 596 ]]></help> | |
| 597 <expand macro="citations"/> | |
| 598 </tool> |
