Mercurial > repos > recetox > matchms_add_key
annotate matchms_add_key.xml @ 0:ea00a749ec1f draft
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
| author | recetox |
|---|---|
| date | Thu, 12 Oct 2023 13:26:04 +0000 |
| parents | |
| children | fb80536001bc |
| rev | line source |
|---|---|
|
0
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
1 <tool id="matchms_add_key" name="matchms add key" version="@TOOL_VERSION@+galaxy1" profile="21.09"> |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
2 <description>Set metadata key in MSP to static value</description> |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
3 |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
4 <macros> |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
5 <import>macros.xml</import> |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
6 <import>help.xml</import> |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
7 </macros> |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
8 |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
9 <expand macro="creator"/> |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
10 |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
11 <edam_operations> |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
12 <edam_operation>operation_2409</edam_operation> |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
13 </edam_operations> |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
14 <expand macro="bio.tools"/> |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
15 |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
16 <requirements> |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
17 <requirement type="package" version="@TOOL_VERSION@">matchms</requirement> |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
18 </requirements> |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
19 |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
20 <command detect_errors='aggressive'><![CDATA[ |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
21 python ${matchms_python_cli} |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
22 ]]></command> |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
23 |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
24 <configfiles> |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
25 <configfile name="matchms_python_cli"> |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
26 @init_logger@ |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
27 |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
28 from matchms.importing import load_from_msp |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
29 from matchms.exporting import save_as_msp |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
30 spectra = list(load_from_msp("${spectral_library}", metadata_harmonization = "False")) |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
31 new_spectra = [] |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
32 for spectrum in spectra: |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
33 spectrum.set("${key}", "${value}") |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
34 new_spectra.append(spectrum) |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
35 save_as_msp(new_spectra, "${output}") |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
36 </configfile> |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
37 </configfiles> |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
38 |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
39 <inputs> |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
40 <param label="Spectra file" name="spectral_library" type="data" format="msp" |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
41 help="Mass spectral library file to add key." /> |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
42 |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
43 <param label="Attribute Name" name="key" type="text" value="" help="Name of the attribute which will be assigned to all spectra records in the MSP." /> |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
44 <param label="Value" name="value" type="text" value="" help="Value of the attribute which will be assigned to all spectra records in the MSP." /> |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
45 </inputs> |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
46 |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
47 <outputs> |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
48 <data label="${tool.name} on ${on_string}" name="output" format="msp"> |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
49 </data> |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
50 </outputs> |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
51 |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
52 <tests> |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
53 <test> |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
54 <param name="spectral_library" value="filtering/input.msp" ftype="msp"/> |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
55 <param name="key" value="tool_used"/> |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
56 <param name="value" value="matchms"/> |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
57 <output name="output" file="out_matchms_add_key.msp" ftype="msp"/> |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
58 </test> |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
59 </tests> |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
60 |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
61 <help><![CDATA[ |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
62 Description |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
63 The tool take MSP file as an input and take as parameters the name of the |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
64 attribute and its value which will be assigned to all spectra records in the MSP. |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
65 ]]></help> |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
66 |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
67 <citations> |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
68 <citation type="doi">https://doi.org/10.5281/zenodo.6035335</citation> |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
69 </citations> |
|
ea00a749ec1f
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit b1cc1aebf796f170d93e3dd46ffcdefdc7b8018a
recetox
parents:
diff
changeset
|
70 </tool> |
