Mercurial > repos > ebi-gxa > scanpy_filter_genes
comparison scanpy-filter-genes.xml @ 9:4bc377096eea draft
planemo upload for repository https://github.com/ebi-gene-expression-group/container-galaxy-sc-tertiary/tree/develop/tools/tertiary-analysis/scanpy commit 367d978e52fac9467a804009c5013f53c06765f0
author | ebi-gxa |
---|---|
date | Tue, 26 Nov 2019 05:52:26 -0500 |
parents | 88bccd53d18a |
children | 6d571e4e5839 |
comparison
equal
deleted
inserted
replaced
8:88bccd53d18a | 9:4bc377096eea |
---|---|
1 <?xml version="1.0" encoding="utf-8"?> | 1 <?xml version="1.0" encoding="utf-8"?> |
2 <tool id="scanpy_filter_genes" name="Scanpy FilterGenes" version="@TOOL_VERSION@+galaxy6"> | 2 <tool id="scanpy_filter_genes" name="Scanpy FilterGenes" version="@TOOL_VERSION@+galaxy7"> |
3 <description>based on counts and numbers of cells expressed</description> | 3 <description>based on counts and numbers of cells expressed</description> |
4 <macros> | 4 <macros> |
5 <import>scanpy_macros2.xml</import> | 5 <import>scanpy_macros2.xml</import> |
6 </macros> | 6 </macros> |
7 <expand macro="requirements"/> | 7 <expand macro="requirements"/> |
8 <command detect_errors="exit_code"><![CDATA[ | 8 <command detect_errors="exit_code"><![CDATA[ |
9 ln -s '${input_obj_file}' input.h5 && | 9 ln -s '${input_obj_file}' input.h5 && |
10 PYTHONIOENCODING=utf-8 scanpy-filter-genes | 10 PYTHONIOENCODING=utf-8 scanpy-filter-genes |
11 #if $parameters | 11 #if $parameters |
12 #set pars = ' '.join(["--param 'g:{name}' {min} {max}".format(**$p) for $p in $parameters]) | 12 #for $p in $parameters |
13 ${pars} | 13 #set $min = $p.min |
14 #set $max = $p.max | |
15 #if $p.name.startswith('pct_') | |
16 #set $min = float($min) / 100 | |
17 #set $max = float($max) / 100 | |
18 #end if | |
19 --param 'g:$p.name' $min $max | |
20 #end for | |
14 #end if | 21 #end if |
15 #if $categories | 22 #if $categories |
16 #set cats = ' '.join(["--category 'g:{name}' '{negate}{values}'".format(**$c) for $c in $categories]) | 23 #set cats = ' '.join(["--category 'g:{name}' '{negate}{values}'".format(**$c) for $c in $categories]) |
17 ${cats} | 24 ${cats} |
18 #end if | 25 #end if |
19 #if $subsets | 26 #if $subsets |
20 #set subs = ' '.join(["--subset 'g:{name}' '{subset}'".format(**$s) for $s in $subsets]) | 27 #set subs = ' '.join(["--subset 'g:{name}' '{subset}'".format(**$s) for $s in $subsets]) |
21 ${subs} | 28 ${subs} |
22 #end if | 29 #end if |
30 $force_recalc | |
23 @INPUT_OPTS@ | 31 @INPUT_OPTS@ |
24 @OUTPUT_OPTS@ | 32 @OUTPUT_OPTS@ |
25 @EXPORT_MTX_OPTS@ | 33 @EXPORT_MTX_OPTS@ |
26 ]]></command> | 34 ]]></command> |
27 | 35 |
28 <inputs> | 36 <inputs> |
29 <expand macro="input_object_params"/> | 37 <expand macro="input_object_params"/> |
30 <expand macro="output_object_params"/> | 38 <expand macro="output_object_params"/> |
31 | 39 |
32 <repeat name="parameters" title="Parameters used to filter genes" min="1"> | 40 <repeat name="parameters" title="Parameters to select genes to keep" min="1"> |
33 <param name="name" type="text" value="n_cells" label="Name of parameter to filter on" help="for example n_genes or n_counts"> | 41 <param name="name" type="text" value="n_cells" label="Name of parameter to filter on" help="for example n_genes or n_counts"> |
34 <option value="n_cells">n_cells</option> | 42 <option value="n_cells">n_cells</option> |
35 <option value="n_counts">n_counts</option> | 43 <option value="n_counts">n_counts</option> |
36 </param> | 44 </param> |
37 <param name="min" type="float" min="0" value="0" label="Min value"/> | 45 <param name="min" type="float" min="0" value="0" label="Min value" help="Genes with value below min will be discarded."/> |
38 <param name="max" type="float" min="0" value="1e9" label="Max value"/> | 46 <param name="max" type="float" min="0" value="1e9" label="Max value" help="Genes with value above max will be discarded."/> |
39 </repeat> | 47 </repeat> |
40 | 48 |
41 <repeat name="categories" title="Categories used to filter genes" min="0"> | 49 <repeat name="categories" title="Categories to select genes to keep (unless negate is checked)" min="0"> |
42 <param name="name" type="text" value="" label="Name of the categorical variable to filter on"/> | 50 <param name="name" type="text" value="" label="Name of the categorical variable to filter on"/> |
43 <param name="values" type="text" value="" label="Comma-separated list of categories"/> | 51 <param name="values" type="text" value="" label="Comma-separated list of categories"/> |
44 <param name="negate" type="boolean" truevalue="!" falsevalue="" checked="false" label="Apply as negative filter" help="If enabled, specified categories will be removed rather than retained."/> | 52 <param name="negate" type="boolean" truevalue="!" falsevalue="" checked="false" label="Apply as negative filter" help="If enabled, specified categories will be removed rather than retained."/> |
45 </repeat> | 53 </repeat> |
46 | 54 |
47 <repeat name="subsets" title="Subsets used to filter genes" min="0"> | 55 <repeat name="subsets" title="Subsets to select genes to keep" min="0"> |
48 <param name="name" type="text" value="" label="Name of the categorical variable to filter on"/> | 56 <param name="name" type="text" value="" label="Name of the categorical variable to filter on"/> |
49 <param name="subset" type="data" format="tabular" label="List of values to keep" help="A one-column headerless text file is required"/> | 57 <param name="subset" type="data" format="tabular" label="List of values to keep" help="A one-column headerless text file is required"/> |
50 </repeat> | 58 </repeat> |
59 <param name="force_recalc" label="Force recalculation of QC vars" type="boolean" truevalue="--force-recalc" falsevalue="" help="If set, it will recalculate pcts and other existing QC vars, overwriting existing ones."/> | |
51 <expand macro="export_mtx_params"/> | 60 <expand macro="export_mtx_params"/> |
52 </inputs> | 61 </inputs> |
53 | 62 |
54 <outputs> | 63 <outputs> |
55 <expand macro="output_data_obj" description="Filtered cells"/> | 64 <expand macro="output_data_obj" description="Filtered cells"/> |