Mercurial > repos > recetox > bioconductor_msnbase_centroid
comparison bioconductor_msnbase_centroid.xml @ 0:4018639dc0a5 draft default tip
planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/bioconductor-msnbase commit 8a94b9932a94c323a33dfe858ee0a2c57fb04701
| author | recetox |
|---|---|
| date | Fri, 24 Jan 2025 15:58:07 +0000 |
| parents | |
| children |
comparison
equal
deleted
inserted
replaced
| -1:000000000000 | 0:4018639dc0a5 |
|---|---|
| 1 <tool id="bioconductor_msnbase_centroid" name="bioconductor-msnbase centroid" version="@TOOL_VERSION@+galaxy@VERSION_SUFFIX@" profile="20.01" license="MIT"> | |
| 2 <description>centroid raw profile-mode MS data</description> | |
| 3 <macros> | |
| 4 <import>macros.xml</import> | |
| 5 </macros> | |
| 6 <expand macro="xrefs"/> | |
| 7 <expand macro="creator"/> | |
| 8 <expand macro="requirements"/> | |
| 9 <command detect_errors="exit_code"><![CDATA[ | |
| 10 Rscript "${run_script}" | |
| 11 ]]></command> | |
| 12 <configfiles> | |
| 13 <configfile name="run_script"><![CDATA[ | |
| 14 data_prof <- MSnbase::readMSData("$input_file", msLevel = $mslevel) | |
| 15 | |
| 16 data_centroided <- MSnbase::pickPeaks( | |
| 17 data_prof, | |
| 18 halfWindowSize = ${halfWindowSize}, | |
| 19 method = "${estimate_noise_method}", | |
| 20 SNR = ${snr}, | |
| 21 refineMz = "${refinement.method}", | |
| 22 #if "$refinement.method" == "kNeighbors" | |
| 23 k = ${refinement.k} | |
| 24 #else if "$refinement.method" == "descendPeak" | |
| 25 signalPercentage = ${refinement.signal_percentage}, | |
| 26 stopAtTwo = ${refinement.stop_at_two} | |
| 27 #end if | |
| 28 ) | |
| 29 | |
| 30 MSnbase::writeMSData( | |
| 31 data_centroided, | |
| 32 file = "centroided.mzml", | |
| 33 copy = TRUE, | |
| 34 outformat = "mzml" | |
| 35 ) | |
| 36 ]]></configfile> | |
| 37 </configfiles> | |
| 38 <inputs> | |
| 39 <param name="input_file" type="data" format="mzml" label="Input mzML File" | |
| 40 help="The input mzML file containing the mass spectrometry data to be centroided."/> | |
| 41 <param argument="mslevel" type="boolean" truevalue="2" falsevalue="1" checked="false" label="MS2" | |
| 42 help="Specify if the dataset contains MS2 (tandem mass spectrometry) data." /> | |
| 43 <param name="halfWindowSize" type="integer" label="Half window size" min="1" value="2" | |
| 44 help="The half window size for the centroiding method. This determines the number of data points on either side of the center point to include in the centroiding calculation."/> | |
| 45 <param name="estimate_noise_method" type="select" label="Noise estimation method" | |
| 46 help="Method to choose to estimate the noise in the spectrum."> | |
| 47 <option value="MAD" selected="true">Median Absolute Deviation</option> | |
| 48 <option value="SuperSmoother">Friedman's Super Smoother</option> | |
| 49 </param> | |
| 50 <param argument="--snr" type="float" min="0" value="3" label="Signal-to-noise ratio (SNR)" | |
| 51 help="The signal-to-noise ratio threshold for removing noisy signals." /> | |
| 52 <conditional name="refinement"> | |
| 53 <param name="method" type="select" label="Peak refinement method" | |
| 54 help="The method refines the m/z value of the identified centroids by considering data points that belong (most likely) to the same mass peak. | |
| 55 The m/z value is calculated as an intensity weighted average of the m/z values within the peak region. | |
| 56 How the peak region is defined depends on the method chosen."> | |
| 57 <option value="none" selected="true">None</option> | |
| 58 <option value="kNeighbors">K-Neighbors</option> | |
| 59 <option value="descendPeak">Descend Peak</option> | |
| 60 </param> | |
| 61 <when value="kNeighbors"> | |
| 62 <param argument="--k" type="integer" min="1" max="10" value="2" label="K" | |
| 63 help="The number of 2*K nearest neighbors to consider for m/z interpolation during peak refinement."/> | |
| 64 </when> | |
| 65 <when value="descendPeak"> | |
| 66 <param argument="--signal_percentage" type="integer" min="0" max="100" value="20" label="Intensity threshold (%)" | |
| 67 help="The signal intensity cutoff threshold (as a percentage) for including values in the m/z calculation during peak refinement." /> | |
| 68 <param argument="stop_at_two" type="boolean" truevalue="TRUE" falsevalue="FALSE" checked="false" label="Stop at two" | |
| 69 help="Specify whether to stop the descent only after encountering two increasing scans, instead of stopping at the first increasing scan." /> | |
| 70 </when> | |
| 71 <when value="none"/> | |
| 72 </conditional> | |
| 73 </inputs> | |
| 74 <outputs> | |
| 75 <data name="output_file" format="mzml" label="${on_string} centroided with refinement ${refinement.method}" from_work_dir="centroided.mzml"/> | |
| 76 </outputs> | |
| 77 <tests> | |
| 78 <test> | |
| 79 <param name="input_file" value="29_qc_no_dil_milliq_subset.mzML"/> | |
| 80 <output name="output_file"> | |
| 81 <assert_contents> | |
| 82 <expand macro="assertions_centroiding"/> | |
| 83 </assert_contents> | |
| 84 </output> | |
| 85 </test> | |
| 86 <test> | |
| 87 <param name="input_file" value="29_qc_no_dil_milliq_subset.mzML"/> | |
| 88 <param name="method" value="kNeighbors"/> | |
| 89 <param name="k" value="3"/> | |
| 90 <output name="output_file"> | |
| 91 <assert_contents> | |
| 92 <expand macro="assertions_centroiding"/> | |
| 93 </assert_contents> | |
| 94 </output> | |
| 95 </test> | |
| 96 <test> | |
| 97 <param name="input_file" value="29_qc_no_dil_milliq_subset.mzML"/> | |
| 98 <param name="method" value="descendPeak"/> | |
| 99 <param name="signal_percentage" value="10"/> | |
| 100 <output name="output_file"> | |
| 101 <assert_contents> | |
| 102 <expand macro="assertions_centroiding"/> | |
| 103 </assert_contents> | |
| 104 </output> | |
| 105 </test> | |
| 106 </tests> | |
| 107 <help><![CDATA[ | |
| 108 .. class:: infomark | |
| 109 | |
| 110 **What it does** | |
| 111 | |
| 112 This tool performs centroiding on mass spectrometry data using the MSnbase package in R. Centroiding is a process that converts profile mode data to centroid mode by identifying the peaks in the mass spectrum and representing them as single points. | |
| 113 | |
| 114 **Usage** | |
| 115 | |
| 116 - **Input**: Provide the input mzML file containing the mass spectrometry data to be centroided. | |
| 117 - **Parameters**: | |
| 118 - **Input mzML File**: The input mzML file containing the mass spectrometry data to be centroided. | |
| 119 - **MS2**: Specify if the dataset contains MS2 (tandem mass spectrometry) data. | |
| 120 - **Half window size**: The number of data points on either side of the center point to include in the centroiding calculation. | |
| 121 - **Noise estimation method**: Choose the method to estimate the noise in the spectrum. Options include Median Absolute Deviation (MAD) and Friedman's Super Smoother. | |
| 122 - **Signal-to-noise ratio (SNR)**: The signal-to-noise ratio threshold for removing noisy signals. A higher value will result in more noise being filtered out. | |
| 123 - **Peak refinement method**: Select the method to refine the m/z value of the identified centroids. Options include None, K-Neighbors, and Descend Peak. | |
| 124 - **K**: The number of 2*K nearest neighbors to consider for m/z interpolation during peak refinement (only applicable if K-Neighbors method is selected). | |
| 125 - **Intensity threshold (%)**: The signal intensity cutoff threshold (as a percentage) for including values in the m/z calculation during peak refinement (only applicable if Descend Peak method is selected). | |
| 126 - **Stop at two**: Specify whether to stop the descent only after encountering two increasing scans, instead of stopping at the first increasing scan (only applicable if Descend Peak method is selected). | |
| 127 - **Output**: The centroided mzML file. | |
| 128 | |
| 129 **Input** | |
| 130 | |
| 131 - **Input mzML File**: The input mzML file containing the mass spectrometry data to be centroided. | |
| 132 | |
| 133 **Output** | |
| 134 | |
| 135 - **Output mzML File**: The resulting mzML file after applying the centroiding algorithm. | |
| 136 | |
| 137 **References** | |
| 138 | |
| 139 For more detailed information, please refer to the original documentation available via Bioconductor: https://bioconductor.org/packages/release/bioc/html/MSnbase.html | |
| 140 ]]></help> | |
| 141 <expand macro="citations"/> | |
| 142 </tool> |
