Mercurial > repos > iuc > mzmine_batch
comparison mzmine_batch.xml @ 0:02e802817d48 draft
planemo upload for repository https://github.com/workflow4metabolomics/tools-metabolomics/blob/master/tools/mzmine/ commit dbad3fc09e109598befcec3a9a000496f4e0c9dd
author | iuc |
---|---|
date | Sat, 21 Oct 2023 10:29:31 +0000 |
parents | |
children | 90d60c9da21e |
comparison
equal
deleted
inserted
replaced
-1:000000000000 | 0:02e802817d48 |
---|---|
1 <tool id="mzmine_batch" name="MZMine batch" version="@TOOL_VERSION@+galaxy@VERSION_SUFFIX@" profile="21.05"> | |
2 <macros> | |
3 <token name="@TOOL_VERSION@">3.6.0</token> | |
4 <token name="@VERSION_SUFFIX@">0</token> | |
5 </macros> | |
6 <xrefs> | |
7 <xref type="bio.tools">mzmine</xref> | |
8 </xrefs> | |
9 <requirements> | |
10 <requirement type="package" version="@TOOL_VERSION@">mzmine</requirement> | |
11 </requirements> | |
12 <command detect_errors="exit_code"><![CDATA[ | |
13 #import re | |
14 | |
15 mkdir -p input && | |
16 #for $i in $input | |
17 #set escaped_i = re.sub('[^\s\w\-\.]', '_', str($i.element_identifier)) | |
18 ln -s '$i' 'input/$escaped_i'.$i.ext && | |
19 echo 'input/$escaped_i'.$i.ext >> input.txt && | |
20 #end for | |
21 | |
22 #if $libraries | |
23 mkdir -p libraries && | |
24 #for $l in $libraries | |
25 #set escaped_l = re.sub('[^\s\w\-\.]', '_', str($l.element_identifier)) | |
26 ln -s '$l' 'libraries/$escaped_l'.$l.ext && | |
27 echo 'libraries/$escaped_l'.$l.ext >> libraries.txt && | |
28 #end for | |
29 #end if | |
30 ## modify output paths in batch XML to relative path | |
31 ## - any output will be redirected to ./output/BASENAME | |
32 mkdir -p output/ && | |
33 | |
34 sed -e 's@<current_file>.*[\\\/]\([^\\\/]\+\)</current_file>@<current_file>./output/\1</current_file>@' '$batch' > batch.xml && | |
35 | |
36 mzmine | |
37 --batch 'batch.xml' | |
38 --input 'input.txt' | |
39 #if $libraries | |
40 --libraries 'libraries.txt' | |
41 #end if | |
42 --memory "\${MZMINE_MEMORY:-none}" | |
43 --temp "\${TMPDIR:-\$_GALAXY_JOB_TMP_DIR}" | |
44 --threads \${GALAXY_SLOTS:-1} | |
45 ## ignored parameters | |
46 ## -p,--pref <arg> preferences file | |
47 ## -r,--running keep MZmine running in headless mode | |
48 ## -tdfpseudoprofile Loads pseudo-profile frame spectra for tdf files | |
49 ## instead of centroided spectra. | |
50 ## -tsfprofile Loads profile spectra from .tsf data instead of | |
51 ## centroid spectra. | |
52 ]]></command> | |
53 <inputs> | |
54 <param argument="--batch" type="data" format="xml" label="MZMine batch file" help="XML batch file (ideally created with version @TOOL_VERSION@)"/> | |
55 <param argument="--input" type="data" format="mzml,mzxml,csv" multiple="true" label="Spectra (mzml)"/> | |
56 <param argument="--libraries" type="data" format="json,mgf,msp" multiple="true" optional="true" label="Spectral libraries"/> | |
57 </inputs> | |
58 <outputs> | |
59 <collection name="output" type="list"> | |
60 <discover_datasets pattern="__name_and_ext__" directory="output"/> | |
61 </collection> | |
62 </outputs> | |
63 <tests> | |
64 <test> | |
65 <param name="batch" value="test_small.xml" ftype="xml"/> | |
66 <param name="input" value="DOM_a.mzML,DOM_b.mzXML"/> | |
67 <param name="libraries" value="GNPS-FAULKNERLEGACY.json" ftype="json"/> | |
68 <!-- <param name="input" location="https://raw.githubusercontent.com/mzmine/mzmine3/master/src/test/resources/rawdatafiles/DOM_a.mzML"/> --> | |
69 <!-- <param name="input" location="https://raw.githubusercontent.com/mzmine/mzmine3/master/src/test/resources/rawdatafiles/DOM_a.mzML,https://raw.githubusercontent.com/mzmine/mzmine3/master/src/test/resources/rawdatafiles/DOM_b.mzXML"/> | |
70 <param name="libraries" location="https://external.gnps2.org/gnpslibrary/GNPS-FAULKNERLEGACY.json" ftype="json"/> --> | |
71 <output_collection name="output" count="3" type="list"> | |
72 <element name="test2_iimn_gnps" ftype="mgf"> | |
73 <assert_contents> | |
74 <has_n_lines n="2103"/> | |
75 <has_text text="BEGIN IONS"/> | |
76 </assert_contents> | |
77 </element> | |
78 <element name="test2_iimn_gnps_quant" ftype="csv"> | |
79 <assert_contents> | |
80 <has_n_lines n="34"/> | |
81 <has_n_columns sep="," n="16"/> | |
82 </assert_contents> | |
83 </element> | |
84 <element name="test2_sirius" ftype="mgf"> | |
85 <assert_contents> | |
86 <has_n_lines n="54406"/> | |
87 <has_text text="BEGIN IONS"/> | |
88 </assert_contents> | |
89 </element> | |
90 </output_collection> | |
91 </test> | |
92 </tests> | |
93 <help><![CDATA[ | |
94 MZmine 3 is an open-source software for mass-spectrometry data processing, with the main focus on LC-MS data. | |
95 | |
96 This Galaxy tool allows to execute MZmine batches. That is you can create MZmine batch (XML) files thatdescribe the parameters of a MZmine analysis using the MZmine GUI | |
97 and use this to execute such an analysis on the Galaxy platform. | |
98 | |
99 **Inputs** | |
100 | |
101 - MZMine batch file in XML format. This file describes the parameters for a MZmine batch analysis. It can be generated with the MZmine GUI (preferentiall with a matching version, i.e. @TOOL_VERSION@). | |
102 - Input spectra in mzml format | |
103 - Spectra libraries in mgf or json format (optional) | |
104 | |
105 **Outputs** | |
106 | |
107 Galaxy will store all outputs of MZMine in a single collection. When specifying the batch XML | |
108 file one should pay attention to use file extensions that correspond to Galaxy datatypes | |
109 (which allows Galaxy to easily autodetect the datatype). The following extensions can be used | |
110 (lower/upper case does not matter): | |
111 | |
112 - mzml | |
113 - netcdf | |
114 - mgf | |
115 - txt | |
116 - msp | |
117 - csv | |
118 - mztab | |
119 - mztab2 (this is mzTab-m) | |
120 - json | |
121 - tabular (Galaxy's tsv implementation) | |
122 | |
123 Specific datasets from the collection can be accessed using the *Extract dataset* tool, e.g. | |
124 for further processing in Galaxy. | |
125 ]]></help> | |
126 <citations> | |
127 <citation type="doi">10.1038/s41587-023-01690-2</citation> | |
128 </citations> | |
129 </tool> |