annotate matchms_metadata_export.xml @ 4:73c902331bbc draft

planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit a493624c962d820d962bd81c14aceede5d5be5b4
author recetox
date Thu, 19 Oct 2023 15:24:22 +0000
parents 7504a8f93699
children c01868645f1b
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
4
73c902331bbc planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit a493624c962d820d962bd81c14aceede5d5be5b4
recetox
parents: 3
diff changeset
1 <tool id="matchms_metadata_export" name="matchms metadata export" version="@TOOL_VERSION@+galaxy0" profile="21.09">
0
dfdbccfa8753 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit c10d901c526d0895869d18a1d1bdd1ea58ed7473
recetox
parents:
diff changeset
2 <description>extract all metadata from mass spectra file to tabular format</description>
dfdbccfa8753 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit c10d901c526d0895869d18a1d1bdd1ea58ed7473
recetox
parents:
diff changeset
3 <macros>
dfdbccfa8753 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit c10d901c526d0895869d18a1d1bdd1ea58ed7473
recetox
parents:
diff changeset
4 <import>macros.xml</import>
2
f04610d25411 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit f79a5b51599254817727bc9028b9797ea994cb4e
recetox
parents: 0
diff changeset
5 <import>help.xml</import>
0
dfdbccfa8753 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit c10d901c526d0895869d18a1d1bdd1ea58ed7473
recetox
parents:
diff changeset
6 </macros>
dfdbccfa8753 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit c10d901c526d0895869d18a1d1bdd1ea58ed7473
recetox
parents:
diff changeset
7 <expand macro="creator"/>
2
f04610d25411 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit f79a5b51599254817727bc9028b9797ea994cb4e
recetox
parents: 0
diff changeset
8 <expand macro="bio.tools"/>
f04610d25411 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit f79a5b51599254817727bc9028b9797ea994cb4e
recetox
parents: 0
diff changeset
9
0
dfdbccfa8753 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit c10d901c526d0895869d18a1d1bdd1ea58ed7473
recetox
parents:
diff changeset
10 <requirements>
2
f04610d25411 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit f79a5b51599254817727bc9028b9797ea994cb4e
recetox
parents: 0
diff changeset
11 <requirement type="package" version="@TOOL_VERSION@">matchms</requirement>
0
dfdbccfa8753 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit c10d901c526d0895869d18a1d1bdd1ea58ed7473
recetox
parents:
diff changeset
12 </requirements>
dfdbccfa8753 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit c10d901c526d0895869d18a1d1bdd1ea58ed7473
recetox
parents:
diff changeset
13
dfdbccfa8753 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit c10d901c526d0895869d18a1d1bdd1ea58ed7473
recetox
parents:
diff changeset
14 <command detect_errors='aggressive'><![CDATA[
dfdbccfa8753 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit c10d901c526d0895869d18a1d1bdd1ea58ed7473
recetox
parents:
diff changeset
15 python ${matchms_python_cli}
dfdbccfa8753 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit c10d901c526d0895869d18a1d1bdd1ea58ed7473
recetox
parents:
diff changeset
16 ]]></command>
dfdbccfa8753 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit c10d901c526d0895869d18a1d1bdd1ea58ed7473
recetox
parents:
diff changeset
17
dfdbccfa8753 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit c10d901c526d0895869d18a1d1bdd1ea58ed7473
recetox
parents:
diff changeset
18 <configfiles>
dfdbccfa8753 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit c10d901c526d0895869d18a1d1bdd1ea58ed7473
recetox
parents:
diff changeset
19 <configfile name="matchms_python_cli">
dfdbccfa8753 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit c10d901c526d0895869d18a1d1bdd1ea58ed7473
recetox
parents:
diff changeset
20 from matchms.importing import load_from_msp, load_from_mgf
dfdbccfa8753 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit c10d901c526d0895869d18a1d1bdd1ea58ed7473
recetox
parents:
diff changeset
21 from matchms.exporting.metadata_export import export_metadata_as_csv
dfdbccfa8753 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit c10d901c526d0895869d18a1d1bdd1ea58ed7473
recetox
parents:
diff changeset
22
dfdbccfa8753 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit c10d901c526d0895869d18a1d1bdd1ea58ed7473
recetox
parents:
diff changeset
23 spectra_list = list(load_from_${input_file.ext}("${input_file}", $harmonize_metadata))
dfdbccfa8753 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit c10d901c526d0895869d18a1d1bdd1ea58ed7473
recetox
parents:
diff changeset
24
dfdbccfa8753 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit c10d901c526d0895869d18a1d1bdd1ea58ed7473
recetox
parents:
diff changeset
25 export_metadata_as_csv(spectra_list, "${output_file}")
dfdbccfa8753 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit c10d901c526d0895869d18a1d1bdd1ea58ed7473
recetox
parents:
diff changeset
26 </configfile>
dfdbccfa8753 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit c10d901c526d0895869d18a1d1bdd1ea58ed7473
recetox
parents:
diff changeset
27 </configfiles>
dfdbccfa8753 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit c10d901c526d0895869d18a1d1bdd1ea58ed7473
recetox
parents:
diff changeset
28
dfdbccfa8753 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit c10d901c526d0895869d18a1d1bdd1ea58ed7473
recetox
parents:
diff changeset
29 <inputs>
dfdbccfa8753 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit c10d901c526d0895869d18a1d1bdd1ea58ed7473
recetox
parents:
diff changeset
30 <param label="Spectra file" name="input_file" type="data" format="msp,mgf" help="Mass spectral library file."/>
dfdbccfa8753 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit c10d901c526d0895869d18a1d1bdd1ea58ed7473
recetox
parents:
diff changeset
31 <param label="Harmonize metadata" name="harmonize_metadata" type="boolean" truevalue="True" falsevalue="False"
dfdbccfa8753 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit c10d901c526d0895869d18a1d1bdd1ea58ed7473
recetox
parents:
diff changeset
32 checked="false" help="Apply harmonization process on the metadata keys (e.g. parse numeric values, derive precursor mass)."/>
dfdbccfa8753 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit c10d901c526d0895869d18a1d1bdd1ea58ed7473
recetox
parents:
diff changeset
33 </inputs>
dfdbccfa8753 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit c10d901c526d0895869d18a1d1bdd1ea58ed7473
recetox
parents:
diff changeset
34
dfdbccfa8753 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit c10d901c526d0895869d18a1d1bdd1ea58ed7473
recetox
parents:
diff changeset
35 <outputs>
dfdbccfa8753 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit c10d901c526d0895869d18a1d1bdd1ea58ed7473
recetox
parents:
diff changeset
36 <data label="matchms extract metadata on ${on_string}" name="output_file" format="csv"/>
dfdbccfa8753 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit c10d901c526d0895869d18a1d1bdd1ea58ed7473
recetox
parents:
diff changeset
37 </outputs>
dfdbccfa8753 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit c10d901c526d0895869d18a1d1bdd1ea58ed7473
recetox
parents:
diff changeset
38
dfdbccfa8753 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit c10d901c526d0895869d18a1d1bdd1ea58ed7473
recetox
parents:
diff changeset
39 <tests>
dfdbccfa8753 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit c10d901c526d0895869d18a1d1bdd1ea58ed7473
recetox
parents:
diff changeset
40 <test>
dfdbccfa8753 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit c10d901c526d0895869d18a1d1bdd1ea58ed7473
recetox
parents:
diff changeset
41 <param name="input_file" value="convert/mgf_out.mgf" ftype="mgf"/>
dfdbccfa8753 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit c10d901c526d0895869d18a1d1bdd1ea58ed7473
recetox
parents:
diff changeset
42 <output name="output_file" file="convert/metadata.csv" ftype="csv" compare="sim_size" delta="0"/>
dfdbccfa8753 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit c10d901c526d0895869d18a1d1bdd1ea58ed7473
recetox
parents:
diff changeset
43 </test>
dfdbccfa8753 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit c10d901c526d0895869d18a1d1bdd1ea58ed7473
recetox
parents:
diff changeset
44 <test>
dfdbccfa8753 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit c10d901c526d0895869d18a1d1bdd1ea58ed7473
recetox
parents:
diff changeset
45 <param name="input_file" value="similarity/RECETOX_Exposome_pesticides_HR_MS_20220323.msp" ftype="msp"/>
dfdbccfa8753 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit c10d901c526d0895869d18a1d1bdd1ea58ed7473
recetox
parents:
diff changeset
46 <output name="output_file" file="convert/metadata.csv" ftype="csv" compare="sim_size" delta="0"/>
dfdbccfa8753 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit c10d901c526d0895869d18a1d1bdd1ea58ed7473
recetox
parents:
diff changeset
47 </test>
dfdbccfa8753 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit c10d901c526d0895869d18a1d1bdd1ea58ed7473
recetox
parents:
diff changeset
48 </tests>
dfdbccfa8753 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit c10d901c526d0895869d18a1d1bdd1ea58ed7473
recetox
parents:
diff changeset
49
2
f04610d25411 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit f79a5b51599254817727bc9028b9797ea994cb4e
recetox
parents: 0
diff changeset
50 <help>
f04610d25411 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit f79a5b51599254817727bc9028b9797ea994cb4e
recetox
parents: 0
diff changeset
51 Documentation
f04610d25411 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit f79a5b51599254817727bc9028b9797ea994cb4e
recetox
parents: 0
diff changeset
52 Mass spectral libraries are often stored in various formats, such as `msp`, `mgf` or `json`.
f04610d25411 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit f79a5b51599254817727bc9028b9797ea994cb4e
recetox
parents: 0
diff changeset
53 This tool can be used to export the metadata accompanying the actual spectral to a tabular file,
f04610d25411 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit f79a5b51599254817727bc9028b9797ea994cb4e
recetox
parents: 0
diff changeset
54 creating a column for each attribute and a row for each spectrum.
f04610d25411 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit f79a5b51599254817727bc9028b9797ea994cb4e
recetox
parents: 0
diff changeset
55 All keys which are present in at least one spectrum are contained in the output.
f04610d25411 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit f79a5b51599254817727bc9028b9797ea994cb4e
recetox
parents: 0
diff changeset
56
f04610d25411 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit f79a5b51599254817727bc9028b9797ea994cb4e
recetox
parents: 0
diff changeset
57 @HELP_matchms@
f04610d25411 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit f79a5b51599254817727bc9028b9797ea994cb4e
recetox
parents: 0
diff changeset
58 </help>
0
dfdbccfa8753 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit c10d901c526d0895869d18a1d1bdd1ea58ed7473
recetox
parents:
diff changeset
59
dfdbccfa8753 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit c10d901c526d0895869d18a1d1bdd1ea58ed7473
recetox
parents:
diff changeset
60 <expand macro="citations"/>
dfdbccfa8753 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/matchms commit c10d901c526d0895869d18a1d1bdd1ea58ed7473
recetox
parents:
diff changeset
61 </tool>