changeset 9:e0bbaf9f7da0 draft

"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/cardinal commit e499c9124d3fd85a7fc47b95c206ce91a5e3678c-dirty"
author galaxyp
date Tue, 03 Nov 2020 22:41:21 +0000
parents 413a1b74f496
children aa479a0cfb43
files macros.xml preprocessing.xml test-data/112_auto_combined.ibd test-data/112_auto_combined.imzml test-data/112_auto_combined.imzml.txt test-data/112_auto_combined_QC.pdf test-data/123_combined.ibd test-data/123_combined.imzml test-data/123_combined.imzml.txt test-data/123_combined_QC.pdf test-data/123_combined_auto.ibd test-data/123_combined_auto.imzml test-data/123_combined_auto.imzml.txt test-data/123_combined_auto.pdf test-data/12_combined.ibd test-data/12_combined.imzml test-data/12_combined.imzml.txt test-data/12_combined_QC.pdf test-data/2123_auto_combined.ibd test-data/2123_auto_combined.imzml test-data/2123_auto_combined.imzml.txt test-data/2123_auto_combined_QC.pdf test-data/Heatmaps_LM8_file16.pdf test-data/Heatmaps_analyze75.pdf test-data/Heatmaps_imzml.pdf test-data/Heatmaps_processed.pdf test-data/Heatmaps_rdata.pdf test-data/Plot_analyze75.pdf test-data/Plot_analyze75_allpixels.pdf test-data/Plot_imzml.pdf test-data/Plot_picked.pdf test-data/Plot_processed.pdf test-data/Plot_rdata.pdf test-data/QC_analyze75.pdf test-data/QC_empty_spectra.pdf test-data/QC_imzml.pdf test-data/QC_rdata.pdf test-data/analyze75_filtered2.pdf test-data/centroids_proc.pdf test-data/centroids_rdata.pdf test-data/cluster_skm.RData test-data/imzml_filtered3.pdf test-data/imzml_filtered4.pdf test-data/imzml_filtered5.pdf test-data/imzml_filtered8.pdf test-data/kmeans_analyze.pdf test-data/out3.ibd test-data/out3.imzml test-data/out3.imzml.txt test-data/out4.ibd test-data/out4.imzml test-data/out4.imzml.txt test-data/out5.ibd test-data/out5.imzml test-data/out5.imzml.txt test-data/out6.ibd test-data/out6.imzml test-data/out6.imzml.txt test-data/out7.ibd test-data/out7.imzml test-data/out7.imzml.txt test-data/out8.ibd test-data/out8.imzml test-data/out8.imzml.txt test-data/pca_imzml.pdf test-data/picked.ibd test-data/picked.imzml test-data/picked.imzml.txt test-data/picked_QC.pdf test-data/preprocessing_results1.ibd test-data/preprocessing_results1.imzml test-data/preprocessing_results1.imzml.txt test-data/preprocessing_results1.pdf test-data/preprocessing_results2.ibd test-data/preprocessing_results2.imzml test-data/preprocessing_results2.imzml.txt test-data/preprocessing_results2.pdf test-data/preprocessing_results3.ibd test-data/preprocessing_results3.imzml test-data/preprocessing_results3.imzml.txt test-data/preprocessing_results3.pdf test-data/preprocessing_results4.ibd test-data/preprocessing_results4.imzml test-data/preprocessing_results4.imzml.txt test-data/preprocessing_results4.pdf test-data/preprocessing_results5.ibd test-data/preprocessing_results5.imzml test-data/preprocessing_results5.imzml.txt test-data/preprocessing_results5.pdf test-data/rdata_notfiltered.pdf test-data/test1.pdf test-data/test2.pdf test-data/test2.rdata test-data/test3.pdf test-data/test4.pdf test-data/test4.rdata test-data/test5.pdf test-data/test6.pdf test-data/test6.rdata test-data/test7.pdf test-data/test7.rdata
diffstat 101 files changed, 251 insertions(+), 263 deletions(-) [+]
line wrap: on
line diff
--- a/macros.xml	Wed May 13 17:56:03 2020 +0000
+++ b/macros.xml	Tue Nov 03 22:41:21 2020 +0000
@@ -1,10 +1,10 @@
 <macros>
-    <token name="@VERSION@">2.4.0</token>
+    <token name="@VERSION@">2.6.0</token>
 
     <xml name="requirements">
         <requirements>
             <requirement type="package" version="@VERSION@">bioconductor-cardinal</requirement>
-            <requirement type="package" version="3.6.1">r-base</requirement>
+            <!--requirement type="package" version="3.6.1">r-base</requirement-->
             <yield/>
         </requirements>
     </xml>
@@ -117,6 +117,13 @@
     <token name="@DATA_PROPERTIES_INRAM@"><![CDATA[ 
 ########################### QC numbers ########################
 ## including intensity calculations which need data in RAM
+
+	int_matrix = as.matrix(spectra(msidata)) ## only load once into RAM, then re-use
+	## Number of NA in spectra matrix
+        NAcount = sum(is.na(int_matrix))
+	## replace NA with zero to calculate data properties based on intensity matrix, no change in msidata
+	int_matrix[is.na(int_matrix)] <- 0
+	
         ## Number of features (mz)
         maxfeatures = length(features(msidata))
         ## Range mz
@@ -131,14 +138,12 @@
         minimumy = min(coord(msidata)[,2])
         maximumy = max(coord(msidata)[,2])
         ## Range of intensities
-        minint = round(min(as.matrix(spectra(msidata)), na.rm=TRUE), digits=2)
-        maxint = round(max(as.matrix(spectra(msidata)), na.rm=TRUE), digits=2)
+        minint = round(min(int_matrix), digits=2)
+        maxint = round(max(int_matrix), digits=2)
         ## Number of intensities > 0, for if conditions
-        npeaks= sum(as.matrix(spectra(msidata))>0, na.rm=TRUE)
+        npeaks= sum(int_matrix>0)
         ## Number of NA in spectra matrix
-        NAcount = sum(is.na(spectra(msidata)))
-        ## Number of NA in spectra matrix
-        infcount = sum(is.infinite(as.matrix(spectra(msidata))))
+        infcount = sum(is.infinite(int_matrix))
         ## Number of duplicated coordinates
         dupl_coord = sum(duplicated(coord(msidata)))
         properties = c("Number of m/z features",
@@ -175,7 +180,7 @@
 
             - imzml file (upload imzml and ibd file via the "composite" function) `Introduction to the imzml format <https://ms-imaging.org/wp/imzml/>`_
             - Analyze7.5 (upload hdr, img and t2m file via the "composite" function)
-            - Cardinal "MSImageSet" data saved as .RData
+            - Cardinal "MSImageSet" or "MSImagingExperiment" saved as .RData
     ]]></token>
     <token name="@MZ_TABULAR_INPUT_DESCRIPTION@"><![CDATA[
         - Optional tabular file with m/z values: 
@@ -243,7 +248,7 @@
             </param>
             <when value="no_processed"/>
             <when value="processed">
-                <param name="accuracy" type="float" value="50" label="Mass accuracy to which the m/z values will be binned" help="This should be set to the native accuracy of the mass spectrometer, if known"/>
+                <param name="accuracy" type="float" value="50" label="Mass accuracy to which the m/z values will be binned"/>
                 <param name="units" display="radio" type="select" label="Unit of the mass accuracy" help="either m/z or ppm">
                     <option value="mz" >mz</option>
                     <option value="ppm" selected="True" >ppm</option>
--- a/preprocessing.xml	Wed May 13 17:56:03 2020 +0000
+++ b/preprocessing.xml	Tue Nov 03 22:41:21 2020 +0000
@@ -1,4 +1,4 @@
-<tool id="cardinal_preprocessing" name="MSI preprocessing" version="@VERSION@.2">
+<tool id="cardinal_preprocessing" name="MSI preprocessing" version="@VERSION@.1">
     <description>
         mass spectrometry imaging preprocessing
     </description>
@@ -7,7 +7,7 @@
     </macros>
     <expand macro="requirements">
         <requirement type="package" version="2.3">r-gridextra</requirement>
-        <requirement type="package" version="3.2.1">r-ggplot2</requirement>
+        <requirement type="package" version="3.3.2">r-ggplot2</requirement>
     </expand>
     <command detect_errors="exit_code">
     <![CDATA[
@@ -74,7 +74,7 @@
     ## Choose random spectra for QC plots
     random_spectra = sample(pixels(msidata), 4, replace=FALSE)
     par(oma=c(0,0,2,0))
-    print(plot(msidata, pixel=random_spectra))
+    print(plot(msidata, pixel=random_spectra, col="black"))
     title("Input spectra", outer=TRUE, line=0)
 
     ############################### Preprocessing steps ###########################
@@ -88,10 +88,6 @@
             print('Normalization')
             ##normalization
 
-            if (class(msidata) == "MSProcessedImagingExperiment"){
-                msidata = as(msidata, "MSContinuousImagingExperiment")
-            }
-
             msidata = normalize(msidata, method="$method.methods_conditional.methods_for_normalization.normalization_method")
             msidata <- process(msidata, BPPARAM=MulticoreParam(workers=number_cpu))
 
@@ -105,7 +101,7 @@
             normalized = c(minmz, maxmz,maxfeatures, pixelcount)
             QC_numbers= cbind(QC_numbers, normalized)
             vectorofactions = append(vectorofactions, "normalized")
-            print(plot(msidata, pixel=random_spectra))
+            print(plot(msidata, pixel=random_spectra, col="black"))
             title("Spectra after normalization", outer=TRUE, line=0)
 
     ############################### Baseline reduction ###########################
@@ -114,10 +110,6 @@
             print('Baseline_reduction')
             ##baseline reduction
 
-            if (class(msidata) == "MSProcessedImagingExperiment"){
-                msidata = as(msidata, "MSContinuousImagingExperiment")
-            }
-
             msidata = reduceBaseline(msidata, method="median", blocks=$method.methods_conditional.blocks_baseline, spar=$method.methods_conditional.spar_baseline)
             msidata <- process(msidata, BPPARAM=MulticoreParam(workers=number_cpu))
 
@@ -130,7 +122,7 @@
             baseline = c(minmz, maxmz,maxfeatures, pixelcount)
             QC_numbers= cbind(QC_numbers, baseline)
             vectorofactions = append(vectorofactions, "baseline red.")
-            print(plot(msidata, pixel=random_spectra))
+            print(plot(msidata, pixel=random_spectra, col="black"))
             title("Spectra after baseline reduction", outer=TRUE, line=0)
 
     ############################### Smoothing ###########################
@@ -139,11 +131,6 @@
             print('Smoothing')
             ## Smoothing
 
-            if (class(msidata) == "MSProcessedImagingExperiment"){
-                msidata = as(msidata, "MSContinuousImagingExperiment")
-            }
-
-
             #if str( $method.methods_conditional.methods_for_smoothing.smoothing_method) == 'gaussian':
                 print('gaussian smoothing')
 
@@ -176,7 +163,7 @@
             smoothed = c(minmz, maxmz,maxfeatures, pixelcount)
             QC_numbers= cbind(QC_numbers, smoothed)
             vectorofactions = append(vectorofactions, "smoothed")
-            print(plot(msidata, pixel=random_spectra))
+            print(plot(msidata, pixel=random_spectra, col="black"))
             title("Spectra after smoothing", outer=TRUE, line=0)
 
 
@@ -211,7 +198,7 @@
             mz_aligned = c(minmz, maxmz,maxfeatures, pixelcount)
             QC_numbers= cbind(QC_numbers, mz_aligned)
             vectorofactions = append(vectorofactions, "mz aligned")
-            print(plot(msidata, pixel=random_spectra))
+            print(plot(msidata, pixel=random_spectra, col="black"))
             title("Spectra after m/z alignment", outer=TRUE, line=0)
 
 
@@ -240,10 +227,6 @@
             #end if
             msidata <- process(msidata, BPPARAM=MulticoreParam(workers=number_cpu))
 
-            #if str($method.methods_conditional.imzml_output) == "cont_format":
-                #set $continuous_format = True
-            #end if
-
 
             ############################### QC ###########################
 
@@ -254,7 +237,7 @@
             picked = c(minmz, maxmz,maxfeatures, pixelcount)
             QC_numbers= cbind(QC_numbers, picked)
             vectorofactions = append(vectorofactions, "picked")
-            print(plot(msidata, pixel=random_spectra))
+            print(plot(msidata, pixel=random_spectra, col="black"))
             title("Spectra after peak picking", outer=TRUE, line=0)
 
     ############################### Peak alignment ###########################
@@ -285,9 +268,6 @@
 
             msidata <- process(msidata, BPPARAM=MulticoreParam(workers=number_cpu))
 
-            #if str($method.methods_conditional.imzml_output) == "cont_format":
-                #set $continuous_format = True
-            #end if
 
             ############################### QC ###########################
 
@@ -298,7 +278,7 @@
             aligned = c(minmz, maxmz,maxfeatures, pixelcount)
             QC_numbers= cbind(QC_numbers, aligned)
             vectorofactions = append(vectorofactions, "aligned")
-            print(plot(msidata, pixel=random_spectra))
+            print(plot(msidata, pixel=random_spectra, col="black"))
             title("Spectra after alignment", outer=TRUE, line=0)
 
     ############################### Peak filtering ###########################
@@ -318,7 +298,7 @@
             filtered = c(minmz, maxmz,maxfeatures, pixelcount)
             QC_numbers= cbind(QC_numbers, filtered)
             vectorofactions = append(vectorofactions, "filtered")
-            print(plot(msidata, pixel=random_spectra))
+            print(plot(msidata, pixel=random_spectra, col="black"))
             title("Spectra after filtering", outer=TRUE, line=0)
 
     ############################### Peak binning ###########################
@@ -343,39 +323,43 @@
             peak_binned = c(minmz, maxmz,maxfeatures, pixelcount)
             QC_numbers= cbind(QC_numbers, peak_binned)
             vectorofactions = append(vectorofactions, "peak binned")
-            print(plot(msidata, pixel=random_spectra))
+            print(plot(msidata, pixel=random_spectra, col="black"))
             title("Spectra after peak binning", outer=TRUE, line=0)
 
 
-    ############################### Data reduction ###########################
+    ############################### Mass binning ###########################
 
-        #elif str( $method.methods_conditional.preprocessing_method) == 'Data_reduction':
-            print('Data_reduction')
+        #elif str( $method.methods_conditional.preprocessing_method) == 'Mass_binning':
+            print('mass binning')
 
-            ## these functions only work on MSImageSet
-            msidata = as(msidata, "MSImageSet")
+            #if str( $method.methods_conditional.mz_range.features_filtering) == 'change_mz_range':
+
+                #if str($processed_cond.processed_file) == "processed":
 
-            #if str( $method.methods_conditional.methods_for_reduction.reduction_method) == 'bin':
-                print('bin reduction')
+                msidata = mse_bin = mzBin(msidata,resolution=$method.methods_conditional.bin_width, from=$method.methods_conditional.mz_range.min_mz, to=$method.methods_conditional.mz_range.max_mz, units="$method.methods_conditional.bin_units", fun="$method.methods_conditional.bin_fun")
+                
+                #else 
+                    ## continuous file cannot be binned from m/z to m/z, therefore first cut m/z range and then do mzbin:
+                    msidata = msidata[mz(msidata) >= $method.methods_conditional.mz_range.min_mz & mz(msidata) <= $method.methods_conditional.mz_range.max_mz,]
+                    msidata = mse_bin = mzBin(msidata,resolution=$method.methods_conditional.bin_width, units="$method.methods_conditional.bin_units", fun="$method.methods_conditional.bin_fun")
+                #end if
 
-                msidata = reduceDimension(msidata, method="bin", width=$method.methods_conditional.methods_for_reduction.bin_width, units="$method.methods_conditional.methods_for_reduction.bin_units", fun=$method.methods_conditional.methods_for_reduction.bin_fun)
+		   
+	    #elif str( $method.methods_conditional.mz_range.features_filtering) == 'none':	    
+
+                msidata = mse_bin = mzBin(msidata,resolution=$method.methods_conditional.bin_width, units="$method.methods_conditional.bin_units", fun=$method.methods_conditional.bin_fun)
 
+            #end if
+             
+            msidata <- process(msidata, BPPARAM=MulticoreParam(workers=number_cpu))
+                
                 ## optional: replace NA with 0
-                #if $method.methods_conditional.methods_for_reduction.replace_NA_bin:
+                #if $method.methods_conditional.replace_NA_bin:
                     ## count and replace NAs
                     print(paste0("Number of NA that were set to zero after binning:",sum(is.na(spectra(msidata)))))
                     spectra(msidata)[is.na(spectra(msidata))] = 0 
                 #end if
-
-            #elif str( $method.methods_conditional.methods_for_reduction.reduction_method) == 'resample':
-                print('resample reduction')
-
-                msidata = reduceDimension(msidata, method="resample", step=$method.methods_conditional.methods_for_reduction.resample_step)
-            #end if
-
-            ## coercition into new format
-            msidata = as(msidata, "MSImagingExperiment")
-
+                
             ############################### QC ###########################
 
             maxfeatures =nrow(msidata)
@@ -385,8 +369,8 @@
             reduced = c(minmz, maxmz,maxfeatures, pixelcount)
             QC_numbers= cbind(QC_numbers, reduced)
             vectorofactions = append(vectorofactions, "reduced")
-            print(plot(msidata, pixel=random_spectra))
-            title("Spectra after data reduction", outer=TRUE, line=0)
+            print(plot(msidata, pixel=random_spectra, col="black"))
+            title("Spectra after m/z binning", outer=TRUE, line=0)
 
         ############################### Transformation ###########################
 
@@ -428,7 +412,7 @@
             transformed = c(minmz, maxmz,maxfeatures, pixelcount)
             QC_numbers= cbind(QC_numbers, transformed)
             vectorofactions = append(vectorofactions, "transformed")
-            print(plot(msidata, pixel=random_spectra))
+            print(plot(msidata, pixel=random_spectra, col="black"))
             title("Spectra after transformation", outer=TRUE, line=0)
 
             #end if
@@ -438,6 +422,10 @@
     ################################################################################
 
     ## save msidata as imzML file, will only work if there is at least 1 m/z left
+    
+    #if str($imzml_output) == "cont_format":
+        #set $continuous_format = True
+    #end if
 
         if (nrow(msidata) > 0){
             ## make sure that coordinates are integers
@@ -479,7 +467,7 @@
                     <option value="Peak_alignment">Peak alignment</option>
                     <option value="Peak_filtering">Peak filtering</option>
                     <option value="Peak_binning">Peak binning to reference peaks</option>
-                    <option value="Data_reduction">Data reduction</option>
+                    <option value="Mass_binning">m/z binning</option>
                     <option value="Transformation">Transformation</option>
                 </param>
                 <when value="Normalization">
@@ -576,7 +564,6 @@
                         <when value="mad"/>
                         <when value="simple"/>
                     </conditional>
-                <param name="imzml_output" type="boolean" label="imzML output in processed format" checked="True" truevalue="proc_format" falsevalue="cont_format"/>
                 </when>
                 <when value="Peak_alignment">
                     <param name="value_diffalignment" type="float" value="200"
@@ -595,7 +582,6 @@
                             <expand macro="reading_1_column_mz_tabular" label="Tabular file with m/z features to use for alignment. Only the m/z values from the tabular file will be kept."/>
                         </when>
                     </conditional>
-                <param name="imzml_output" type="boolean" label="imzML output in processed format" checked="True" truevalue="proc_format" falsevalue="cont_format" help= "Processed imzML works only in MALDIquant tools, not yet in MSI tools (Cardinal)"/>
                 </when>
                 <when value="Peak_filtering">
                     <param name="frequ_filtering" type="float" value="0.01" max="1" min="0" label="Minimum frequency" help="Peaks that occur in the dataset in lesser proportion than this will be dropped (0.01 --> filtering for 1% of spectra)"/>
@@ -620,31 +606,29 @@
                             <option value="area">area</option>
                     </param>
                 </when>
-                <when value="Data_reduction">
-                    <conditional name="methods_for_reduction">
-                        <param name="reduction_method" type="select" label="Reduction method">
-                            <option value="bin" selected="True">bin</option>
-                            <option value="resample">resample</option>
+                <when value="Mass_binning">
+                    <param name="bin_width" type="float" value="1" label="The width of a bin in m/z or ppm" help="Width must be greater than range of m/z values divided by number of m/z features"/>
+		    <param name="bin_units" type="select" display="radio"
+		           label="Unit for bin">
+		            <option value="mz" selected="True">mz</option>
+		            <option value="ppm">ppm</option>
+		    </param>
+                    <param name="bin_fun" type="select" display="radio"
+                           label="Calculate sum or mean intensity for ions of the same bin">
+                            <option value="mean" selected="True">mean</option>
+                            <option value="sum">sum</option>
+                    </param>
+                    <param name="replace_NA_bin" type="boolean" label="Replace NA with 0" truevalue="TRUE" falsevalue="FALSE" checked="True" help="Binning can introduce NAs, should they be replaced with 0"/>
+                    <conditional name="mz_range">
+            		 <param name="features_filtering" type="select" label="Select m/z feature filtering option">
+                            <option value="none" selected="True">none</option>
+                            <option value="change_mz_range">change m/z range</option>
                         </param>
-                        <when value="bin">
-                            <param name="bin_width" type="float" value="1"
-                                   label="The width of a bin in m/z or ppm" help="Width must be greater than range of m/z values divided by number of m/z features"/>
-                            <param name="bin_units" type="select" display="radio"
-                                   label="Unit for bin">
-                                    <option value="mz" selected="True">mz</option>
-                                    <option value="ppm">ppm</option>
-                            </param>
-                            <param name="bin_fun" type="select" display="radio"
-                                   label="Calculate sum or mean intensity for ions of the same bin">
-                                    <option value="mean" selected="True">mean</option>
-                                    <option value="sum">sum</option>
-                            </param>
-                            <param name="replace_NA_bin" type="boolean" label="Replace NA with 0" truevalue="TRUE" falsevalue="FALSE" checked="True" help="Binning can introduce NAs, should they be replaced with 0"/>
-                        </when>
-                        <when value="resample">
-                            <param name="resample_step" type="float" value="1"
-                                   label="The step size in m/z" help="Step size must be greater than range of m/z values divided by number of m/z features"/>
-                        </when>
+			    <when value="none"/>
+			    <when value="change_mz_range">
+				<param name="min_mz" type="float" value="1" label="Minimum value for m/z"/>
+				<param name="max_mz" type="float" value="10000" label="Maximum value for m/z"/>
+			    </when>
                     </conditional>
                 </when>
                 <when value="Transformation">
@@ -661,6 +645,7 @@
                 </when>
             </conditional>
         </repeat>
+        <param name="imzml_output" type="boolean" label="imzML output in processed format" checked="True" truevalue="proc_format" falsevalue="cont_format"/>
     </inputs>
     <outputs>
         <data format="imzml" name="outfile_imzml" label="${tool.name} on ${on_string}: imzML"/>
@@ -696,13 +681,11 @@
                     <param name="blocks_picking" value="3"/>
                     <param name="window_picking" value="3"/>
                     <param name="SNR_picking_method" value="3"/>
-                    <param name="imzml_output" value="cont_format"/>
                 </conditional>
             </repeat>
             <repeat name="methods">
                 <conditional name="methods_conditional">
                     <param name="preprocessing_method" value="Peak_alignment"/>
-                    <param name="imzml_output" value="cont_format"/>
                 </conditional>
             </repeat>
             <repeat name="methods">
@@ -719,6 +702,7 @@
                         </conditional>
                 </conditional>
             </repeat>
+            <param name="imzml_output" value="cont_format"/>
             <output name="QC_overview" file="preprocessing_results1.pdf" compare="sim_size"/>
             <output name="outfile_imzml" ftype="imzml" file="preprocessing_results1.imzml.txt" compare="sim_size">
                 <extra_files type="file" file="preprocessing_results1.imzml" name="imzml" lines_diff="6"/>
@@ -736,15 +720,14 @@
                     <conditional name="methods_for_picking">
                         <param name="picking_method" value="adaptive"/>
                     </conditional>
-                    <param name="imzml_output" value="cont_format"/>
                 </conditional>
             </repeat>
             <repeat name="methods">
                 <conditional name="methods_conditional">
                     <param name="preprocessing_method" value="Peak_alignment"/>
-                    <param name="imzml_output" value="cont_format"/>
                 </conditional>
             </repeat>
+            <param name="imzml_output" value="cont_format"/>
             <output name="QC_overview" file="preprocessing_results2.pdf" compare="sim_size"/>
             <output name="outfile_imzml" ftype="imzml" file="preprocessing_results2.imzml.txt" compare="sim_size">
                 <extra_files type="file" file="preprocessing_results2.imzml" name="imzml" lines_diff="6"/>
@@ -800,11 +783,9 @@
             </repeat>
             <repeat name="methods">
                 <conditional name="methods_conditional">
-                    <param name="preprocessing_method" value="Data_reduction"/>
-                    <conditional name="methods_for_reduction">
-                        <param name="reduction_method" value="bin"/>
+                    <param name="preprocessing_method" value="Mass_binning"/>
                         <param name="bin_width" value="0.1"/>
-                    </conditional>
+                        <param name="bin_units" value="mz"/>
                 </conditional>
             </repeat>
             <output name="QC_overview" file="preprocessing_results4.pdf" compare="sim_size"/>
@@ -817,7 +798,7 @@
             <expand macro="processed_infile_imzml"/>
             <conditional name="processed_cond">
                 <param name="processed_file" value="processed"/>
-                <param name="accuracy" value="100"/>
+                <param name="accuracy" value="200"/>
                 <param name="units" value="ppm"/>
             </conditional>
             <repeat name="methods">
@@ -855,15 +836,17 @@
 
 **Options**
 
-- Normalization: Normalization of intensities to total ion current (TIC) or to root-mean-square (RMS)
-- Baseline reduction: Baseline  reduction removes background intensity generated by chemical noise (common in MALDI datasets)
+- Normalization: normalization of intensities to total ion current (TIC) or to root-mean-square (RMS)
+- Baseline reduction: baseline  reduction removes background intensity generated by chemical noise (common in MALDI datasets)
 - Smoothing: Smoothing of the peaks reduces noise and improves peak detection
+- m/z alignment: removes small m/z shifts between spectra 
 - Peak picking: relevant peaks are picked while noise-peaks are removed (needs peak alignment afterwards)
 - Peak alignment: only possible after peak picking, m/z inaccuracies are removed by alignment of same peaks to a common m/z value; if no reference is given the peaks are aligned to the local maxima of the mean spectrum of the current dataset; external reference data can be used from another MSI data file or a tabular file with m/z values, but then only the m/z from the reference will be kept
 - Peak filtering: removes peaks that occur only in a small proportion of pixels. If not sure which cut off to choose run quality control tool first and decide according to the number of peaks per m/z plot
-- Peak binning: extracts peaks intensities (from a profile dataset) for a list of m/z (reference) values
-- Data reduction: binning or resampling to reduce data
+- Peak binning: extracts peaks intensities, either peak height or area under curve (from a profile dataset) for a list of m/z (reference) values
+- m/z binning: generates new m/z bins
 - Transformation: log2 or squareroot transformation of all intensities; when using log2 transformation zero intensities will become NA, this can lead to compatibility problems. 
+                    
 
 **Output**
 
Binary file test-data/112_auto_combined.ibd has changed
--- a/test-data/112_auto_combined.imzml	Wed May 13 17:56:03 2020 +0000
+++ b/test-data/112_auto_combined.imzml	Tue Nov 03 22:41:21 2020 +0000
@@ -9,8 +9,8 @@
 		<fileContent>
 			<cvParam cvRef="MS" accession="MS:1000579" name="MS1 spectrum" value="" />
 			<cvParam cvRef="MS" accession="MS:1000128" name="profile spectrum" value="" />
-			<cvParam cvRef="IMS" accession="IMS:1000080" name="universally unique identifier" value="de720b1f-c3fa-4596-b054-284efaff29fc" />
-			<cvParam cvRef="IMS" accession="IMS:1000091" name="ibd SHA-1" value="040b9782d76e25ebe9a6b7c27fdda7e27e711674" />
+			<cvParam cvRef="IMS" accession="IMS:1000080" name="universally unique identifier" value="23f1e1c8-aaa5-4d04-ab81-da14f7d24507" />
+			<cvParam cvRef="IMS" accession="IMS:1000091" name="ibd SHA-1" value="b2e009b6e72791420e704b751b4fc1a0f36bf420" />
 			<cvParam cvRef="IMS" accession="IMS:1000030" name="continuous" value="" />
 		</fileContent>
 	</fileDescription>
@@ -42,7 +42,7 @@
 		</sample>
 	</sampleList>
 	<softwareList count="1">
-		<software id="Cardinal" version="2.4.0">
+		<software id="Cardinal" version="2.6.0">
 			<cvParam cvRef="MS" accession="MS:1000799" name="custom unreleased software tool" value="" />
 		</software>
 	</softwareList>
--- a/test-data/112_auto_combined.imzml.txt	Wed May 13 17:56:03 2020 +0000
+++ b/test-data/112_auto_combined.imzml.txt	Tue Nov 03 22:41:21 2020 +0000
@@ -1,4 +1,4 @@
 imzML file:
 total 556
--rw-r--r-- 1 meli meli 537552 Apr 21 12:46 ibd
--rw-r--r-- 1 meli meli  27497 Apr 21 12:46 imzml
+-rw-rw-r-- 1 meli meli 537552 Aug 30 13:50 ibd
+-rw-rw-r-- 1 meli meli  27497 Aug 30 13:50 imzml
Binary file test-data/112_auto_combined_QC.pdf has changed
Binary file test-data/123_combined.ibd has changed
--- a/test-data/123_combined.imzml	Wed May 13 17:56:03 2020 +0000
+++ b/test-data/123_combined.imzml	Tue Nov 03 22:41:21 2020 +0000
@@ -9,8 +9,8 @@
 		<fileContent>
 			<cvParam cvRef="MS" accession="MS:1000579" name="MS1 spectrum" value="" />
 			<cvParam cvRef="MS" accession="MS:1000128" name="profile spectrum" value="" />
-			<cvParam cvRef="IMS" accession="IMS:1000080" name="universally unique identifier" value="c9f19079-a92c-4995-b4ee-48d2766994a8" />
-			<cvParam cvRef="IMS" accession="IMS:1000091" name="ibd SHA-1" value="889b1020d3d844330f13a360be4b2bd0b65d11a1" />
+			<cvParam cvRef="IMS" accession="IMS:1000080" name="universally unique identifier" value="383dcc6e-fa4e-4ffe-8523-9cd0c3bd2571" />
+			<cvParam cvRef="IMS" accession="IMS:1000091" name="ibd SHA-1" value="2cd98028c7ab9bd53b698168b508a0ac74f256c9" />
 			<cvParam cvRef="IMS" accession="IMS:1000030" name="continuous" value="" />
 		</fileContent>
 	</fileDescription>
@@ -42,7 +42,7 @@
 		</sample>
 	</sampleList>
 	<softwareList count="1">
-		<software id="Cardinal" version="2.4.0">
+		<software id="Cardinal" version="2.6.0">
 			<cvParam cvRef="MS" accession="MS:1000799" name="custom unreleased software tool" value="" />
 		</software>
 	</softwareList>
--- a/test-data/123_combined.imzml.txt	Wed May 13 17:56:03 2020 +0000
+++ b/test-data/123_combined.imzml.txt	Tue Nov 03 22:41:21 2020 +0000
@@ -1,4 +1,4 @@
 imzML file:
 total 452
--rw-r--r-- 1 meli meli 436764 Apr 21 12:41 ibd
--rw-r--r-- 1 meli meli  22855 Apr 21 12:41 imzml
+-rw-rw-r-- 1 meli meli 436764 Aug 30 13:46 ibd
+-rw-rw-r-- 1 meli meli  22855 Aug 30 13:46 imzml
Binary file test-data/123_combined_QC.pdf has changed
Binary file test-data/123_combined_auto.ibd has changed
--- a/test-data/123_combined_auto.imzml	Wed May 13 17:56:03 2020 +0000
+++ b/test-data/123_combined_auto.imzml	Tue Nov 03 22:41:21 2020 +0000
@@ -9,8 +9,8 @@
 		<fileContent>
 			<cvParam cvRef="MS" accession="MS:1000579" name="MS1 spectrum" value="" />
 			<cvParam cvRef="MS" accession="MS:1000128" name="profile spectrum" value="" />
-			<cvParam cvRef="IMS" accession="IMS:1000080" name="universally unique identifier" value="386d1a7c-e065-4bf1-96a6-019586133b29" />
-			<cvParam cvRef="IMS" accession="IMS:1000091" name="ibd SHA-1" value="9bdafd878211e7d0c8fd0ef11bd534cbacfe7d40" />
+			<cvParam cvRef="IMS" accession="IMS:1000080" name="universally unique identifier" value="ae23e625-6ac2-4a33-be4a-b73af67bc0dd" />
+			<cvParam cvRef="IMS" accession="IMS:1000091" name="ibd SHA-1" value="1b81e4b14567ea9da1177c0490f636d0823b2aac" />
 			<cvParam cvRef="IMS" accession="IMS:1000030" name="continuous" value="" />
 		</fileContent>
 	</fileDescription>
@@ -42,7 +42,7 @@
 		</sample>
 	</sampleList>
 	<softwareList count="1">
-		<software id="Cardinal" version="2.4.0">
+		<software id="Cardinal" version="2.6.0">
 			<cvParam cvRef="MS" accession="MS:1000799" name="custom unreleased software tool" value="" />
 		</software>
 	</softwareList>
--- a/test-data/123_combined_auto.imzml.txt	Wed May 13 17:56:03 2020 +0000
+++ b/test-data/123_combined_auto.imzml.txt	Tue Nov 03 22:41:21 2020 +0000
@@ -1,4 +1,4 @@
 imzML file:
 total 452
--rw-r--r-- 1 meli meli 436764 Apr 21 12:43 ibd
--rw-r--r-- 1 meli meli  22860 Apr 21 12:43 imzml
+-rw-rw-r-- 1 meli meli 436764 Aug 30 13:48 ibd
+-rw-rw-r-- 1 meli meli  22860 Aug 30 13:48 imzml
Binary file test-data/123_combined_auto.pdf has changed
Binary file test-data/12_combined.ibd has changed
--- a/test-data/12_combined.imzml	Wed May 13 17:56:03 2020 +0000
+++ b/test-data/12_combined.imzml	Tue Nov 03 22:41:21 2020 +0000
@@ -9,8 +9,8 @@
 		<fileContent>
 			<cvParam cvRef="MS" accession="MS:1000579" name="MS1 spectrum" value="" />
 			<cvParam cvRef="MS" accession="MS:1000128" name="profile spectrum" value="" />
-			<cvParam cvRef="IMS" accession="IMS:1000080" name="universally unique identifier" value="57f26041-833d-4843-ba25-0037f2c35f51" />
-			<cvParam cvRef="IMS" accession="IMS:1000091" name="ibd SHA-1" value="c271b37214900da9960cd3bcb748cc5bc377cfec" />
+			<cvParam cvRef="IMS" accession="IMS:1000080" name="universally unique identifier" value="85ec7820-8e87-4fb2-b74a-5b9cd8cf24d6" />
+			<cvParam cvRef="IMS" accession="IMS:1000091" name="ibd SHA-1" value="d8a4e14091441873e8969f3b6b249f55b4d95146" />
 			<cvParam cvRef="IMS" accession="IMS:1000030" name="continuous" value="" />
 		</fileContent>
 	</fileDescription>
@@ -42,7 +42,7 @@
 		</sample>
 	</sampleList>
 	<softwareList count="1">
-		<software id="Cardinal" version="2.4.0">
+		<software id="Cardinal" version="2.6.0">
 			<cvParam cvRef="MS" accession="MS:1000799" name="custom unreleased software tool" value="" />
 		</software>
 	</softwareList>
--- a/test-data/12_combined.imzml.txt	Wed May 13 17:56:03 2020 +0000
+++ b/test-data/12_combined.imzml.txt	Tue Nov 03 22:41:21 2020 +0000
@@ -1,4 +1,4 @@
 imzML file:
 total 352
--rw-r--r-- 1 meli meli 335976 Apr 21 12:45 ibd
--rw-r--r-- 1 meli meli  18225 Apr 21 12:45 imzml
+-rw-rw-r-- 1 meli meli 335976 Aug 30 13:49 ibd
+-rw-rw-r-- 1 meli meli  18225 Aug 30 13:49 imzml
Binary file test-data/12_combined_QC.pdf has changed
Binary file test-data/2123_auto_combined.ibd has changed
--- a/test-data/2123_auto_combined.imzml	Wed May 13 17:56:03 2020 +0000
+++ b/test-data/2123_auto_combined.imzml	Tue Nov 03 22:41:21 2020 +0000
@@ -9,8 +9,8 @@
 		<fileContent>
 			<cvParam cvRef="MS" accession="MS:1000579" name="MS1 spectrum" value="" />
 			<cvParam cvRef="MS" accession="MS:1000128" name="profile spectrum" value="" />
-			<cvParam cvRef="IMS" accession="IMS:1000080" name="universally unique identifier" value="1c0a127a-8417-47ef-a049-553b9d56de81" />
-			<cvParam cvRef="IMS" accession="IMS:1000091" name="ibd SHA-1" value="5113bf7d09e0b1a584238aa6c5242f50eeef839b" />
+			<cvParam cvRef="IMS" accession="IMS:1000080" name="universally unique identifier" value="d5abe155-9afd-4249-aaf3-8fc631c1fd10" />
+			<cvParam cvRef="IMS" accession="IMS:1000091" name="ibd SHA-1" value="3c93096f299dc50ca088d712feca19f8bf2d5152" />
 			<cvParam cvRef="IMS" accession="IMS:1000030" name="continuous" value="" />
 		</fileContent>
 	</fileDescription>
@@ -42,7 +42,7 @@
 		</sample>
 	</sampleList>
 	<softwareList count="1">
-		<software id="Cardinal" version="2.4.0">
+		<software id="Cardinal" version="2.6.0">
 			<cvParam cvRef="MS" accession="MS:1000799" name="custom unreleased software tool" value="" />
 		</software>
 	</softwareList>
--- a/test-data/2123_auto_combined.imzml.txt	Wed May 13 17:56:03 2020 +0000
+++ b/test-data/2123_auto_combined.imzml.txt	Tue Nov 03 22:41:21 2020 +0000
@@ -1,4 +1,4 @@
 imzML file:
 total 656
--rw-r--r-- 1 meli meli 638340 Apr 21 12:46 ibd
--rw-r--r-- 1 meli meli  32132 Apr 21 12:46 imzml
+-rw-rw-r-- 1 meli meli 638340 Aug 30 13:50 ibd
+-rw-rw-r-- 1 meli meli  32132 Aug 30 13:50 imzml
Binary file test-data/2123_auto_combined_QC.pdf has changed
Binary file test-data/Heatmaps_LM8_file16.pdf has changed
Binary file test-data/Heatmaps_analyze75.pdf has changed
Binary file test-data/Heatmaps_imzml.pdf has changed
Binary file test-data/Heatmaps_processed.pdf has changed
Binary file test-data/Heatmaps_rdata.pdf has changed
Binary file test-data/Plot_analyze75.pdf has changed
Binary file test-data/Plot_analyze75_allpixels.pdf has changed
Binary file test-data/Plot_imzml.pdf has changed
Binary file test-data/Plot_picked.pdf has changed
Binary file test-data/Plot_processed.pdf has changed
Binary file test-data/Plot_rdata.pdf has changed
Binary file test-data/QC_analyze75.pdf has changed
Binary file test-data/QC_empty_spectra.pdf has changed
Binary file test-data/QC_imzml.pdf has changed
Binary file test-data/QC_rdata.pdf has changed
Binary file test-data/analyze75_filtered2.pdf has changed
Binary file test-data/centroids_proc.pdf has changed
Binary file test-data/centroids_rdata.pdf has changed
Binary file test-data/cluster_skm.RData has changed
Binary file test-data/imzml_filtered3.pdf has changed
Binary file test-data/imzml_filtered4.pdf has changed
Binary file test-data/imzml_filtered5.pdf has changed
Binary file test-data/imzml_filtered8.pdf has changed
Binary file test-data/kmeans_analyze.pdf has changed
Binary file test-data/out3.ibd has changed
--- a/test-data/out3.imzml	Wed May 13 17:56:03 2020 +0000
+++ b/test-data/out3.imzml	Tue Nov 03 22:41:21 2020 +0000
@@ -9,8 +9,8 @@
 		<fileContent>
 			<cvParam cvRef="MS" accession="MS:1000579" name="MS1 spectrum" value="" />
 			<cvParam cvRef="MS" accession="MS:1000128" name="profile spectrum" value="" />
-			<cvParam cvRef="IMS" accession="IMS:1000080" name="universally unique identifier" value="7cde7a72-9a6b-4ed9-a809-79ca20bf45b4" />
-			<cvParam cvRef="IMS" accession="IMS:1000091" name="ibd SHA-1" value="4a26497a6ddfc9a61e9c0e463e4c246c5d734f80" />
+			<cvParam cvRef="IMS" accession="IMS:1000080" name="universally unique identifier" value="97f42eea-750c-49e4-b46d-08c548dc3b9d" />
+			<cvParam cvRef="IMS" accession="IMS:1000091" name="ibd SHA-1" value="4e046226f81e9c78255df625ca3546ef26dd0693" />
 			<cvParam cvRef="IMS" accession="IMS:1000030" name="continuous" value="" />
 		</fileContent>
 	</fileDescription>
@@ -42,7 +42,7 @@
 		</sample>
 	</sampleList>
 	<softwareList count="1">
-		<software id="Cardinal" version="2.4.0">
+		<software id="Cardinal" version="2.6.0">
 			<cvParam cvRef="MS" accession="MS:1000799" name="custom unreleased software tool" value="" />
 		</software>
 	</softwareList>
--- a/test-data/out3.imzml.txt	Wed May 13 17:56:03 2020 +0000
+++ b/test-data/out3.imzml.txt	Tue Nov 03 22:41:21 2020 +0000
@@ -1,4 +1,4 @@
 imzML file:
 total 24
--rw-r--r-- 1 meli meli 9616 Mär 24 20:25 ibd
--rw-r--r-- 1 meli meli 8958 Mär 24 20:25 imzml
+-rw-rw-r-- 1 meli meli 9616 Sep 27 10:51 ibd
+-rw-rw-r-- 1 meli meli 8958 Sep 27 10:51 imzml
Binary file test-data/out4.ibd has changed
--- a/test-data/out4.imzml	Wed May 13 17:56:03 2020 +0000
+++ b/test-data/out4.imzml	Tue Nov 03 22:41:21 2020 +0000
@@ -9,8 +9,8 @@
 		<fileContent>
 			<cvParam cvRef="MS" accession="MS:1000579" name="MS1 spectrum" value="" />
 			<cvParam cvRef="MS" accession="MS:1000128" name="profile spectrum" value="" />
-			<cvParam cvRef="IMS" accession="IMS:1000080" name="universally unique identifier" value="b0dec95e-b66f-4c3f-86df-166d942f42c3" />
-			<cvParam cvRef="IMS" accession="IMS:1000091" name="ibd SHA-1" value="d9b557cf2c0e15a0cdd863e50897b07a55a26f31" />
+			<cvParam cvRef="IMS" accession="IMS:1000080" name="universally unique identifier" value="37f3f75a-82c4-47c5-b78e-28fb8697e59b" />
+			<cvParam cvRef="IMS" accession="IMS:1000091" name="ibd SHA-1" value="1746fd2ec8a12707330a78ff5a0ff98cb53dca42" />
 			<cvParam cvRef="IMS" accession="IMS:1000030" name="continuous" value="" />
 		</fileContent>
 	</fileDescription>
@@ -42,7 +42,7 @@
 		</sample>
 	</sampleList>
 	<softwareList count="1">
-		<software id="Cardinal" version="2.4.0">
+		<software id="Cardinal" version="2.6.0">
 			<cvParam cvRef="MS" accession="MS:1000799" name="custom unreleased software tool" value="" />
 		</software>
 	</softwareList>
--- a/test-data/out4.imzml.txt	Wed May 13 17:56:03 2020 +0000
+++ b/test-data/out4.imzml.txt	Tue Nov 03 22:41:21 2020 +0000
@@ -1,4 +1,4 @@
 imzML file:
 total 44
--rw-r--r-- 1 meli meli 28792 Mär 24 19:23 ibd
--rw-r--r-- 1 meli meli 12046 Mär 24 19:23 imzml
+-rw-rw-r-- 1 meli meli 28792 Sep 27 10:52 ibd
+-rw-rw-r-- 1 meli meli 12046 Sep 27 10:52 imzml
Binary file test-data/out5.ibd has changed
--- a/test-data/out5.imzml	Wed May 13 17:56:03 2020 +0000
+++ b/test-data/out5.imzml	Tue Nov 03 22:41:21 2020 +0000
@@ -9,8 +9,8 @@
 		<fileContent>
 			<cvParam cvRef="MS" accession="MS:1000579" name="MS1 spectrum" value="" />
 			<cvParam cvRef="MS" accession="MS:1000128" name="profile spectrum" value="" />
-			<cvParam cvRef="IMS" accession="IMS:1000080" name="universally unique identifier" value="87b0ab73-abe6-4eb6-91ba-b6d493a343bc" />
-			<cvParam cvRef="IMS" accession="IMS:1000091" name="ibd SHA-1" value="9de3a02d0943ecda0717845511a8f7b8f58d1db7" />
+			<cvParam cvRef="IMS" accession="IMS:1000080" name="universally unique identifier" value="37236c7e-6e93-4ccc-9111-1b1153aac713" />
+			<cvParam cvRef="IMS" accession="IMS:1000091" name="ibd SHA-1" value="ccb886aaf3cb7564f518884413ea988c59a1de57" />
 			<cvParam cvRef="IMS" accession="IMS:1000030" name="continuous" value="" />
 		</fileContent>
 	</fileDescription>
@@ -42,7 +42,7 @@
 		</sample>
 	</sampleList>
 	<softwareList count="1">
-		<software id="Cardinal" version="2.4.0">
+		<software id="Cardinal" version="2.6.0">
 			<cvParam cvRef="MS" accession="MS:1000799" name="custom unreleased software tool" value="" />
 		</software>
 	</softwareList>
--- a/test-data/out5.imzml.txt	Wed May 13 17:56:03 2020 +0000
+++ b/test-data/out5.imzml.txt	Tue Nov 03 22:41:21 2020 +0000
@@ -1,4 +1,4 @@
 imzML file:
 total 20
--rw-r--r-- 1 meli meli   380 Mär 24 19:24 ibd
--rw-r--r-- 1 meli meli 13525 Mär 24 19:24 imzml
+-rw-rw-r-- 1 meli meli   380 Sep 27 10:53 ibd
+-rw-rw-r-- 1 meli meli 13525 Sep 27 10:53 imzml
Binary file test-data/out6.ibd has changed
--- a/test-data/out6.imzml	Wed May 13 17:56:03 2020 +0000
+++ b/test-data/out6.imzml	Tue Nov 03 22:41:21 2020 +0000
@@ -9,8 +9,8 @@
 		<fileContent>
 			<cvParam cvRef="MS" accession="MS:1000579" name="MS1 spectrum" value="" />
 			<cvParam cvRef="MS" accession="MS:1000128" name="profile spectrum" value="" />
-			<cvParam cvRef="IMS" accession="IMS:1000080" name="universally unique identifier" value="8b625a26-987e-4e32-b7d4-729efe840814" />
-			<cvParam cvRef="IMS" accession="IMS:1000091" name="ibd SHA-1" value="78e6eb56507d789575ee0495e60f9d44a192c0dd" />
+			<cvParam cvRef="IMS" accession="IMS:1000080" name="universally unique identifier" value="734d4b50-4440-4747-a0e9-de78974d1487" />
+			<cvParam cvRef="IMS" accession="IMS:1000091" name="ibd SHA-1" value="b1636b28fd4e0ab9caf5aaa4c1a40760030a4e73" />
 			<cvParam cvRef="IMS" accession="IMS:1000030" name="continuous" value="" />
 		</fileContent>
 	</fileDescription>
@@ -42,7 +42,7 @@
 		</sample>
 	</sampleList>
 	<softwareList count="1">
-		<software id="Cardinal" version="2.4.0">
+		<software id="Cardinal" version="2.6.0">
 			<cvParam cvRef="MS" accession="MS:1000799" name="custom unreleased software tool" value="" />
 		</software>
 	</softwareList>
--- a/test-data/out6.imzml.txt	Wed May 13 17:56:03 2020 +0000
+++ b/test-data/out6.imzml.txt	Tue Nov 03 22:41:21 2020 +0000
@@ -1,4 +1,4 @@
 imzML file:
 total 164
--rw-r--r-- 1 meli meli 146896 Mär 24 19:25 ibd
--rw-r--r-- 1 meli meli  18221 Mär 24 19:25 imzml
+-rw-rw-r-- 1 meli meli 146896 Sep 27 10:53 ibd
+-rw-rw-r-- 1 meli meli  18221 Sep 27 10:53 imzml
Binary file test-data/out7.ibd has changed
--- a/test-data/out7.imzml	Wed May 13 17:56:03 2020 +0000
+++ b/test-data/out7.imzml	Tue Nov 03 22:41:21 2020 +0000
@@ -9,8 +9,8 @@
 		<fileContent>
 			<cvParam cvRef="MS" accession="MS:1000579" name="MS1 spectrum" value="" />
 			<cvParam cvRef="MS" accession="MS:1000128" name="profile spectrum" value="" />
-			<cvParam cvRef="IMS" accession="IMS:1000080" name="universally unique identifier" value="bf61653e-aa1a-4f9a-a84d-3ff3435ee7fe" />
-			<cvParam cvRef="IMS" accession="IMS:1000091" name="ibd SHA-1" value="352c33defde6728b7dfb83e18ed1c433fa4b8697" />
+			<cvParam cvRef="IMS" accession="IMS:1000080" name="universally unique identifier" value="f81632b3-50b0-4a57-88a2-5f7cf97f9bae" />
+			<cvParam cvRef="IMS" accession="IMS:1000091" name="ibd SHA-1" value="9f88294c3cff3e8c30e80632d6ad616b7db18089" />
 			<cvParam cvRef="IMS" accession="IMS:1000030" name="continuous" value="" />
 		</fileContent>
 	</fileDescription>
@@ -42,7 +42,7 @@
 		</sample>
 	</sampleList>
 	<softwareList count="1">
-		<software id="Cardinal" version="2.4.0">
+		<software id="Cardinal" version="2.6.0">
 			<cvParam cvRef="MS" accession="MS:1000799" name="custom unreleased software tool" value="" />
 		</software>
 	</softwareList>
--- a/test-data/out7.imzml.txt	Wed May 13 17:56:03 2020 +0000
+++ b/test-data/out7.imzml.txt	Tue Nov 03 22:41:21 2020 +0000
@@ -1,4 +1,4 @@
 imzML file:
 total 116
--rw-r--r-- 1 meli meli 95976 Mär 24 19:26 ibd
--rw-r--r-- 1 meli meli 18199 Mär 24 19:26 imzml
+-rw-rw-r-- 1 meli meli 95976 Sep 27 10:54 ibd
+-rw-rw-r-- 1 meli meli 18199 Sep 27 10:54 imzml
Binary file test-data/out8.ibd has changed
--- a/test-data/out8.imzml	Wed May 13 17:56:03 2020 +0000
+++ b/test-data/out8.imzml	Tue Nov 03 22:41:21 2020 +0000
@@ -9,9 +9,9 @@
 		<fileContent>
 			<cvParam cvRef="MS" accession="MS:1000579" name="MS1 spectrum" value="" />
 			<cvParam cvRef="MS" accession="MS:1000128" name="profile spectrum" value="" />
-			<cvParam cvRef="IMS" accession="IMS:1000080" name="universally unique identifier" value="ace74b18-25e2-4722-89f4-6eedc2b62ed8" />
-			<cvParam cvRef="IMS" accession="IMS:1000091" name="ibd SHA-1" value="41d580d8acf3e67df8b63f001fe941da7334861b" />
-			<cvParam cvRef="IMS" accession="IMS:1000031" name="processed" value="" />
+			<cvParam cvRef="IMS" accession="IMS:1000080" name="universally unique identifier" value="02059ae7-7beb-4ecf-92ae-7a767e04bf43" />
+			<cvParam cvRef="IMS" accession="IMS:1000091" name="ibd SHA-1" value="dc3960918fa3008824889b4ac142be1d0534ded8" />
+			<cvParam cvRef="IMS" accession="IMS:1000030" name="continuous" value="" />
 		</fileContent>
 	</fileDescription>
 	<referenceableParamGroupList count="4">
@@ -42,7 +42,7 @@
 		</sample>
 	</sampleList>
 	<softwareList count="1">
-		<software id="Cardinal" version="2.4.0">
+		<software id="Cardinal" version="2.6.0">
 			<cvParam cvRef="MS" accession="MS:1000799" name="custom unreleased software tool" value="" />
 		</software>
 	</softwareList>
@@ -90,15 +90,15 @@
 					<binaryDataArray encodedLength="0">
 						<referenceableParamGroupRef ref="mzArray" />
 						<cvParam cvRef="IMS" accession="IMS:1000102" name="external offset" value="16" />
-						<cvParam cvRef="IMS" accession="IMS:1000103" name="external array length" value="8399" />
-						<cvParam cvRef="IMS" accession="IMS:1000104" name="external encoded length" value="33596" />
+						<cvParam cvRef="IMS" accession="IMS:1000103" name="external array length" value="10367" />
+						<cvParam cvRef="IMS" accession="IMS:1000104" name="external encoded length" value="41468" />
 						<binary />
 					</binaryDataArray>
 					<binaryDataArray encodedLength="0">
 						<referenceableParamGroupRef ref="intensityArray" />
-						<cvParam cvRef="IMS" accession="IMS:1000102" name="external offset" value="33612" />
-						<cvParam cvRef="IMS" accession="IMS:1000103" name="external array length" value="8399" />
-						<cvParam cvRef="IMS" accession="IMS:1000104" name="external encoded length" value="33596" />
+						<cvParam cvRef="IMS" accession="IMS:1000102" name="external offset" value="41484" />
+						<cvParam cvRef="IMS" accession="IMS:1000103" name="external array length" value="10367" />
+						<cvParam cvRef="IMS" accession="IMS:1000104" name="external encoded length" value="41468" />
 						<binary />
 					</binaryDataArray>
 				</binaryDataArrayList>
@@ -118,16 +118,16 @@
 				<binaryDataArrayList count="2">
 					<binaryDataArray encodedLength="0">
 						<referenceableParamGroupRef ref="mzArray" />
-						<cvParam cvRef="IMS" accession="IMS:1000102" name="external offset" value="67208" />
-						<cvParam cvRef="IMS" accession="IMS:1000103" name="external array length" value="8399" />
-						<cvParam cvRef="IMS" accession="IMS:1000104" name="external encoded length" value="33596" />
+						<cvParam cvRef="IMS" accession="IMS:1000102" name="external offset" value="16" />
+						<cvParam cvRef="IMS" accession="IMS:1000103" name="external array length" value="10367" />
+						<cvParam cvRef="IMS" accession="IMS:1000104" name="external encoded length" value="41468" />
 						<binary />
 					</binaryDataArray>
 					<binaryDataArray encodedLength="0">
 						<referenceableParamGroupRef ref="intensityArray" />
-						<cvParam cvRef="IMS" accession="IMS:1000102" name="external offset" value="100804" />
-						<cvParam cvRef="IMS" accession="IMS:1000103" name="external array length" value="8399" />
-						<cvParam cvRef="IMS" accession="IMS:1000104" name="external encoded length" value="33596" />
+						<cvParam cvRef="IMS" accession="IMS:1000102" name="external offset" value="82952" />
+						<cvParam cvRef="IMS" accession="IMS:1000103" name="external array length" value="10367" />
+						<cvParam cvRef="IMS" accession="IMS:1000104" name="external encoded length" value="41468" />
 						<binary />
 					</binaryDataArray>
 				</binaryDataArrayList>
@@ -147,16 +147,16 @@
 				<binaryDataArrayList count="2">
 					<binaryDataArray encodedLength="0">
 						<referenceableParamGroupRef ref="mzArray" />
-						<cvParam cvRef="IMS" accession="IMS:1000102" name="external offset" value="134400" />
-						<cvParam cvRef="IMS" accession="IMS:1000103" name="external array length" value="8399" />
-						<cvParam cvRef="IMS" accession="IMS:1000104" name="external encoded length" value="33596" />
+						<cvParam cvRef="IMS" accession="IMS:1000102" name="external offset" value="16" />
+						<cvParam cvRef="IMS" accession="IMS:1000103" name="external array length" value="10367" />
+						<cvParam cvRef="IMS" accession="IMS:1000104" name="external encoded length" value="41468" />
 						<binary />
 					</binaryDataArray>
 					<binaryDataArray encodedLength="0">
 						<referenceableParamGroupRef ref="intensityArray" />
-						<cvParam cvRef="IMS" accession="IMS:1000102" name="external offset" value="167996" />
-						<cvParam cvRef="IMS" accession="IMS:1000103" name="external array length" value="8399" />
-						<cvParam cvRef="IMS" accession="IMS:1000104" name="external encoded length" value="33596" />
+						<cvParam cvRef="IMS" accession="IMS:1000102" name="external offset" value="124420" />
+						<cvParam cvRef="IMS" accession="IMS:1000103" name="external array length" value="10367" />
+						<cvParam cvRef="IMS" accession="IMS:1000104" name="external encoded length" value="41468" />
 						<binary />
 					</binaryDataArray>
 				</binaryDataArrayList>
@@ -176,16 +176,16 @@
 				<binaryDataArrayList count="2">
 					<binaryDataArray encodedLength="0">
 						<referenceableParamGroupRef ref="mzArray" />
-						<cvParam cvRef="IMS" accession="IMS:1000102" name="external offset" value="201592" />
-						<cvParam cvRef="IMS" accession="IMS:1000103" name="external array length" value="8399" />
-						<cvParam cvRef="IMS" accession="IMS:1000104" name="external encoded length" value="33596" />
+						<cvParam cvRef="IMS" accession="IMS:1000102" name="external offset" value="16" />
+						<cvParam cvRef="IMS" accession="IMS:1000103" name="external array length" value="10367" />
+						<cvParam cvRef="IMS" accession="IMS:1000104" name="external encoded length" value="41468" />
 						<binary />
 					</binaryDataArray>
 					<binaryDataArray encodedLength="0">
 						<referenceableParamGroupRef ref="intensityArray" />
-						<cvParam cvRef="IMS" accession="IMS:1000102" name="external offset" value="235188" />
-						<cvParam cvRef="IMS" accession="IMS:1000103" name="external array length" value="8399" />
-						<cvParam cvRef="IMS" accession="IMS:1000104" name="external encoded length" value="33596" />
+						<cvParam cvRef="IMS" accession="IMS:1000102" name="external offset" value="165888" />
+						<cvParam cvRef="IMS" accession="IMS:1000103" name="external array length" value="10367" />
+						<cvParam cvRef="IMS" accession="IMS:1000104" name="external encoded length" value="41468" />
 						<binary />
 					</binaryDataArray>
 				</binaryDataArrayList>
@@ -205,16 +205,16 @@
 				<binaryDataArrayList count="2">
 					<binaryDataArray encodedLength="0">
 						<referenceableParamGroupRef ref="mzArray" />
-						<cvParam cvRef="IMS" accession="IMS:1000102" name="external offset" value="268784" />
-						<cvParam cvRef="IMS" accession="IMS:1000103" name="external array length" value="8399" />
-						<cvParam cvRef="IMS" accession="IMS:1000104" name="external encoded length" value="33596" />
+						<cvParam cvRef="IMS" accession="IMS:1000102" name="external offset" value="16" />
+						<cvParam cvRef="IMS" accession="IMS:1000103" name="external array length" value="10367" />
+						<cvParam cvRef="IMS" accession="IMS:1000104" name="external encoded length" value="41468" />
 						<binary />
 					</binaryDataArray>
 					<binaryDataArray encodedLength="0">
 						<referenceableParamGroupRef ref="intensityArray" />
-						<cvParam cvRef="IMS" accession="IMS:1000102" name="external offset" value="302380" />
-						<cvParam cvRef="IMS" accession="IMS:1000103" name="external array length" value="8399" />
-						<cvParam cvRef="IMS" accession="IMS:1000104" name="external encoded length" value="33596" />
+						<cvParam cvRef="IMS" accession="IMS:1000102" name="external offset" value="207356" />
+						<cvParam cvRef="IMS" accession="IMS:1000103" name="external array length" value="10367" />
+						<cvParam cvRef="IMS" accession="IMS:1000104" name="external encoded length" value="41468" />
 						<binary />
 					</binaryDataArray>
 				</binaryDataArrayList>
--- a/test-data/out8.imzml.txt	Wed May 13 17:56:03 2020 +0000
+++ b/test-data/out8.imzml.txt	Tue Nov 03 22:41:21 2020 +0000
@@ -1,4 +1,4 @@
 imzML file:
-total 348
--rw-r--r-- 1 meli meli 335976 Mär 24 19:27 ibd
--rw-r--r-- 1 meli meli  12402 Mär 24 19:27 imzml
+total 260
+-rw-rw-r-- 1 meli meli 248824 Sep 27 11:44 ibd
+-rw-rw-r-- 1 meli meli  12397 Sep 27 11:44 imzml
Binary file test-data/pca_imzml.pdf has changed
Binary file test-data/picked.ibd has changed
--- a/test-data/picked.imzml	Wed May 13 17:56:03 2020 +0000
+++ b/test-data/picked.imzml	Tue Nov 03 22:41:21 2020 +0000
@@ -8,8 +8,8 @@
  <fileDescription>
   <fileContent>
    <cvParam cvRef="MS" accession="MS:1000579" name="MS1 spectrum"/>
-   <cvParam cvRef="IMS" accession="IMS:1000080" name="universally unique identifier" value="{cb7c9edc-eee3-4159-a8a1-efdf5fc56a13}"/>
-   <cvParam cvRef="IMS" accession="IMS:1000091" name="ibd SHA-1" value="f3e61f4699108e65bb678cfbbd6208be562f11c9"/>
+   <cvParam cvRef="IMS" accession="IMS:1000080" name="universally unique identifier" value="{19bd2a62-4cc1-4316-b173-25f1de3871f6}"/>
+   <cvParam cvRef="IMS" accession="IMS:1000091" name="ibd SHA-1" value="ca84032e28aa3c04e4f41b74b85ccd1bd6e44107"/>
    <cvParam cvRef="IMS" accession="IMS:1000031" name="processed"/>
    <userParam name="MALDIquantForeign" value="MALDIquant object(s) exported to mzML"/>
   </fileContent>
--- a/test-data/picked.imzml.txt	Wed May 13 17:56:03 2020 +0000
+++ b/test-data/picked.imzml.txt	Tue Nov 03 22:41:21 2020 +0000
@@ -1,4 +1,4 @@
 imzML file:
 total 192
--rw-r--r-- 1 meli meli 157984 Apr 21 12:42 ibd
--rw-r--r-- 1 meli meli  35012 Apr 21 12:42 imzml
+-rw-rw-r-- 1 meli meli 157984 Aug 30 13:47 ibd
+-rw-rw-r-- 1 meli meli  35012 Aug 30 13:47 imzml
Binary file test-data/picked_QC.pdf has changed
Binary file test-data/preprocessing_results1.ibd has changed
--- a/test-data/preprocessing_results1.imzml	Wed May 13 17:56:03 2020 +0000
+++ b/test-data/preprocessing_results1.imzml	Tue Nov 03 22:41:21 2020 +0000
@@ -9,8 +9,8 @@
 		<fileContent>
 			<cvParam cvRef="MS" accession="MS:1000579" name="MS1 spectrum" value="" />
 			<cvParam cvRef="MS" accession="MS:1000127" name="centroid spectrum" value="" />
-			<cvParam cvRef="IMS" accession="IMS:1000080" name="universally unique identifier" value="25fb4349-d529-4b12-8523-a6aa0306ecf4" />
-			<cvParam cvRef="IMS" accession="IMS:1000091" name="ibd SHA-1" value="7f41f9f5efcb31248caefc91b7d6edce87d7f42c" />
+			<cvParam cvRef="IMS" accession="IMS:1000080" name="universally unique identifier" value="07177fdd-3760-4df6-8fe2-53d28b280ae8" />
+			<cvParam cvRef="IMS" accession="IMS:1000091" name="ibd SHA-1" value="749fe32c8243da06001cf4643c5ce4f1ef5a98a8" />
 			<cvParam cvRef="IMS" accession="IMS:1000030" name="continuous" value="" />
 		</fileContent>
 	</fileDescription>
@@ -42,7 +42,7 @@
 		</sample>
 	</sampleList>
 	<softwareList count="1">
-		<software id="Cardinal" version="2.4.0">
+		<software id="Cardinal" version="2.6.0">
 			<cvParam cvRef="MS" accession="MS:1000799" name="custom unreleased software tool" value="" />
 		</software>
 	</softwareList>
--- a/test-data/preprocessing_results1.imzml.txt	Wed May 13 17:56:03 2020 +0000
+++ b/test-data/preprocessing_results1.imzml.txt	Tue Nov 03 22:41:21 2020 +0000
@@ -1,4 +1,4 @@
 imzML file:
 total 24
--rw-r--r-- 1 meli meli   216 Mai 10 17:37 ibd
--rw-r--r-- 1 meli meli 18090 Mai 10 17:37 imzml
+-rw-rw-r-- 1 meli meli   216 Oct  5 19:57 ibd
+-rw-rw-r-- 1 meli meli 18090 Oct  5 19:57 imzml
Binary file test-data/preprocessing_results1.pdf has changed
Binary file test-data/preprocessing_results2.ibd has changed
--- a/test-data/preprocessing_results2.imzml	Wed May 13 17:56:03 2020 +0000
+++ b/test-data/preprocessing_results2.imzml	Tue Nov 03 22:41:21 2020 +0000
@@ -9,8 +9,8 @@
 		<fileContent>
 			<cvParam cvRef="MS" accession="MS:1000579" name="MS1 spectrum" value="" />
 			<cvParam cvRef="MS" accession="MS:1000127" name="centroid spectrum" value="" />
-			<cvParam cvRef="IMS" accession="IMS:1000080" name="universally unique identifier" value="fa59b434-12e0-47fe-b338-814c92daa7d6" />
-			<cvParam cvRef="IMS" accession="IMS:1000091" name="ibd SHA-1" value="5764be27b51a23d8c23e4c93befb9d8e57161bd9" />
+			<cvParam cvRef="IMS" accession="IMS:1000080" name="universally unique identifier" value="503079b4-538a-4be6-b70d-e52542c66482" />
+			<cvParam cvRef="IMS" accession="IMS:1000091" name="ibd SHA-1" value="a597fe6a0184ef339105b3a932f58726a9af549b" />
 			<cvParam cvRef="IMS" accession="IMS:1000030" name="continuous" value="" />
 		</fileContent>
 	</fileDescription>
@@ -42,7 +42,7 @@
 		</sample>
 	</sampleList>
 	<softwareList count="1">
-		<software id="Cardinal" version="2.4.0">
+		<software id="Cardinal" version="2.6.0">
 			<cvParam cvRef="MS" accession="MS:1000799" name="custom unreleased software tool" value="" />
 		</software>
 	</softwareList>
--- a/test-data/preprocessing_results2.imzml.txt	Wed May 13 17:56:03 2020 +0000
+++ b/test-data/preprocessing_results2.imzml.txt	Tue Nov 03 22:41:21 2020 +0000
@@ -1,4 +1,4 @@
 imzML file:
 total 64
--rw-r--r-- 1 meli meli 37404 Mai 10 17:38 ibd
--rw-r--r-- 1 meli meli 22796 Mai 10 17:38 imzml
+-rw-rw-r-- 1 meli meli 37404 Oct  5 19:57 ibd
+-rw-rw-r-- 1 meli meli 22796 Oct  5 19:57 imzml
Binary file test-data/preprocessing_results2.pdf has changed
Binary file test-data/preprocessing_results3.ibd has changed
--- a/test-data/preprocessing_results3.imzml	Wed May 13 17:56:03 2020 +0000
+++ b/test-data/preprocessing_results3.imzml	Tue Nov 03 22:41:21 2020 +0000
@@ -9,8 +9,8 @@
 		<fileContent>
 			<cvParam cvRef="MS" accession="MS:1000579" name="MS1 spectrum" value="" />
 			<cvParam cvRef="MS" accession="MS:1000127" name="centroid spectrum" value="" />
-			<cvParam cvRef="IMS" accession="IMS:1000080" name="universally unique identifier" value="d11b7693-3397-4d1f-9e67-29d952701100" />
-			<cvParam cvRef="IMS" accession="IMS:1000091" name="ibd SHA-1" value="94906879d47bbdcf97126d50c906dfd76e6681e4" />
+			<cvParam cvRef="IMS" accession="IMS:1000080" name="universally unique identifier" value="be549a7e-87af-4413-9b4c-27221f55ee9a" />
+			<cvParam cvRef="IMS" accession="IMS:1000091" name="ibd SHA-1" value="4ee7ca6fb3f60e1adbe196068f86bc3209bace58" />
 			<cvParam cvRef="IMS" accession="IMS:1000031" name="processed" value="" />
 		</fileContent>
 	</fileDescription>
@@ -42,7 +42,7 @@
 		</sample>
 	</sampleList>
 	<softwareList count="1">
-		<software id="Cardinal" version="2.4.0">
+		<software id="Cardinal" version="2.6.0">
 			<cvParam cvRef="MS" accession="MS:1000799" name="custom unreleased software tool" value="" />
 		</software>
 	</softwareList>
--- a/test-data/preprocessing_results3.imzml.txt	Wed May 13 17:56:03 2020 +0000
+++ b/test-data/preprocessing_results3.imzml.txt	Tue Nov 03 22:41:21 2020 +0000
@@ -1,4 +1,4 @@
 imzML file:
 total 24
--rw-r--r-- 1 meli meli   960 Mai 10 17:39 ibd
--rw-r--r-- 1 meli meli 18112 Mai 10 17:39 imzml
+-rw-rw-r-- 1 meli meli   960 Oct  5 19:58 ibd
+-rw-rw-r-- 1 meli meli 18112 Oct  5 19:58 imzml
Binary file test-data/preprocessing_results3.pdf has changed
Binary file test-data/preprocessing_results4.ibd has changed
--- a/test-data/preprocessing_results4.imzml	Wed May 13 17:56:03 2020 +0000
+++ b/test-data/preprocessing_results4.imzml	Tue Nov 03 22:41:21 2020 +0000
@@ -9,8 +9,8 @@
 		<fileContent>
 			<cvParam cvRef="MS" accession="MS:1000579" name="MS1 spectrum" value="" />
 			<cvParam cvRef="MS" accession="MS:1000128" name="profile spectrum" value="" />
-			<cvParam cvRef="IMS" accession="IMS:1000080" name="universally unique identifier" value="c6122884-ceb5-46b6-9160-5d28e8862946" />
-			<cvParam cvRef="IMS" accession="IMS:1000091" name="ibd SHA-1" value="03e4b58b8e63517605164e90b85fe93a851a9c5b" />
+			<cvParam cvRef="IMS" accession="IMS:1000080" name="universally unique identifier" value="48842eaf-40e5-4a3f-831c-2d7a3b7e04b9" />
+			<cvParam cvRef="IMS" accession="IMS:1000091" name="ibd SHA-1" value="2010ba5b7d44695d891cfe3b6674a5699fa610c0" />
 			<cvParam cvRef="IMS" accession="IMS:1000030" name="continuous" value="" />
 		</fileContent>
 	</fileDescription>
@@ -42,7 +42,7 @@
 		</sample>
 	</sampleList>
 	<softwareList count="1">
-		<software id="Cardinal" version="2.4.0">
+		<software id="Cardinal" version="2.6.0">
 			<cvParam cvRef="MS" accession="MS:1000799" name="custom unreleased software tool" value="" />
 		</software>
 	</softwareList>
@@ -86,15 +86,15 @@
 					<binaryDataArray encodedLength="0">
 						<referenceableParamGroupRef ref="mzArray" />
 						<cvParam cvRef="IMS" accession="IMS:1000102" name="external offset" value="16" />
-						<cvParam cvRef="IMS" accession="IMS:1000103" name="external array length" value="1581" />
-						<cvParam cvRef="IMS" accession="IMS:1000104" name="external encoded length" value="6324" />
+						<cvParam cvRef="IMS" accession="IMS:1000103" name="external array length" value="1567" />
+						<cvParam cvRef="IMS" accession="IMS:1000104" name="external encoded length" value="6268" />
 						<binary />
 					</binaryDataArray>
 					<binaryDataArray encodedLength="0">
 						<referenceableParamGroupRef ref="intensityArray" />
-						<cvParam cvRef="IMS" accession="IMS:1000102" name="external offset" value="6340" />
-						<cvParam cvRef="IMS" accession="IMS:1000103" name="external array length" value="1581" />
-						<cvParam cvRef="IMS" accession="IMS:1000104" name="external encoded length" value="6324" />
+						<cvParam cvRef="IMS" accession="IMS:1000102" name="external offset" value="6284" />
+						<cvParam cvRef="IMS" accession="IMS:1000103" name="external array length" value="1567" />
+						<cvParam cvRef="IMS" accession="IMS:1000104" name="external encoded length" value="6268" />
 						<binary />
 					</binaryDataArray>
 				</binaryDataArrayList>
@@ -115,15 +115,15 @@
 					<binaryDataArray encodedLength="0">
 						<referenceableParamGroupRef ref="mzArray" />
 						<cvParam cvRef="IMS" accession="IMS:1000102" name="external offset" value="16" />
-						<cvParam cvRef="IMS" accession="IMS:1000103" name="external array length" value="1581" />
-						<cvParam cvRef="IMS" accession="IMS:1000104" name="external encoded length" value="6324" />
+						<cvParam cvRef="IMS" accession="IMS:1000103" name="external array length" value="1567" />
+						<cvParam cvRef="IMS" accession="IMS:1000104" name="external encoded length" value="6268" />
 						<binary />
 					</binaryDataArray>
 					<binaryDataArray encodedLength="0">
 						<referenceableParamGroupRef ref="intensityArray" />
-						<cvParam cvRef="IMS" accession="IMS:1000102" name="external offset" value="12664" />
-						<cvParam cvRef="IMS" accession="IMS:1000103" name="external array length" value="1581" />
-						<cvParam cvRef="IMS" accession="IMS:1000104" name="external encoded length" value="6324" />
+						<cvParam cvRef="IMS" accession="IMS:1000102" name="external offset" value="12552" />
+						<cvParam cvRef="IMS" accession="IMS:1000103" name="external array length" value="1567" />
+						<cvParam cvRef="IMS" accession="IMS:1000104" name="external encoded length" value="6268" />
 						<binary />
 					</binaryDataArray>
 				</binaryDataArrayList>
@@ -144,15 +144,15 @@
 					<binaryDataArray encodedLength="0">
 						<referenceableParamGroupRef ref="mzArray" />
 						<cvParam cvRef="IMS" accession="IMS:1000102" name="external offset" value="16" />
-						<cvParam cvRef="IMS" accession="IMS:1000103" name="external array length" value="1581" />
-						<cvParam cvRef="IMS" accession="IMS:1000104" name="external encoded length" value="6324" />
+						<cvParam cvRef="IMS" accession="IMS:1000103" name="external array length" value="1567" />
+						<cvParam cvRef="IMS" accession="IMS:1000104" name="external encoded length" value="6268" />
 						<binary />
 					</binaryDataArray>
 					<binaryDataArray encodedLength="0">
 						<referenceableParamGroupRef ref="intensityArray" />
-						<cvParam cvRef="IMS" accession="IMS:1000102" name="external offset" value="18988" />
-						<cvParam cvRef="IMS" accession="IMS:1000103" name="external array length" value="1581" />
-						<cvParam cvRef="IMS" accession="IMS:1000104" name="external encoded length" value="6324" />
+						<cvParam cvRef="IMS" accession="IMS:1000102" name="external offset" value="18820" />
+						<cvParam cvRef="IMS" accession="IMS:1000103" name="external array length" value="1567" />
+						<cvParam cvRef="IMS" accession="IMS:1000104" name="external encoded length" value="6268" />
 						<binary />
 					</binaryDataArray>
 				</binaryDataArrayList>
@@ -173,15 +173,15 @@
 					<binaryDataArray encodedLength="0">
 						<referenceableParamGroupRef ref="mzArray" />
 						<cvParam cvRef="IMS" accession="IMS:1000102" name="external offset" value="16" />
-						<cvParam cvRef="IMS" accession="IMS:1000103" name="external array length" value="1581" />
-						<cvParam cvRef="IMS" accession="IMS:1000104" name="external encoded length" value="6324" />
+						<cvParam cvRef="IMS" accession="IMS:1000103" name="external array length" value="1567" />
+						<cvParam cvRef="IMS" accession="IMS:1000104" name="external encoded length" value="6268" />
 						<binary />
 					</binaryDataArray>
 					<binaryDataArray encodedLength="0">
 						<referenceableParamGroupRef ref="intensityArray" />
-						<cvParam cvRef="IMS" accession="IMS:1000102" name="external offset" value="25312" />
-						<cvParam cvRef="IMS" accession="IMS:1000103" name="external array length" value="1581" />
-						<cvParam cvRef="IMS" accession="IMS:1000104" name="external encoded length" value="6324" />
+						<cvParam cvRef="IMS" accession="IMS:1000102" name="external offset" value="25088" />
+						<cvParam cvRef="IMS" accession="IMS:1000103" name="external array length" value="1567" />
+						<cvParam cvRef="IMS" accession="IMS:1000104" name="external encoded length" value="6268" />
 						<binary />
 					</binaryDataArray>
 				</binaryDataArrayList>
@@ -202,15 +202,15 @@
 					<binaryDataArray encodedLength="0">
 						<referenceableParamGroupRef ref="mzArray" />
 						<cvParam cvRef="IMS" accession="IMS:1000102" name="external offset" value="16" />
-						<cvParam cvRef="IMS" accession="IMS:1000103" name="external array length" value="1581" />
-						<cvParam cvRef="IMS" accession="IMS:1000104" name="external encoded length" value="6324" />
+						<cvParam cvRef="IMS" accession="IMS:1000103" name="external array length" value="1567" />
+						<cvParam cvRef="IMS" accession="IMS:1000104" name="external encoded length" value="6268" />
 						<binary />
 					</binaryDataArray>
 					<binaryDataArray encodedLength="0">
 						<referenceableParamGroupRef ref="intensityArray" />
-						<cvParam cvRef="IMS" accession="IMS:1000102" name="external offset" value="31636" />
-						<cvParam cvRef="IMS" accession="IMS:1000103" name="external array length" value="1581" />
-						<cvParam cvRef="IMS" accession="IMS:1000104" name="external encoded length" value="6324" />
+						<cvParam cvRef="IMS" accession="IMS:1000102" name="external offset" value="31356" />
+						<cvParam cvRef="IMS" accession="IMS:1000103" name="external array length" value="1567" />
+						<cvParam cvRef="IMS" accession="IMS:1000104" name="external encoded length" value="6268" />
 						<binary />
 					</binaryDataArray>
 				</binaryDataArrayList>
@@ -231,15 +231,15 @@
 					<binaryDataArray encodedLength="0">
 						<referenceableParamGroupRef ref="mzArray" />
 						<cvParam cvRef="IMS" accession="IMS:1000102" name="external offset" value="16" />
-						<cvParam cvRef="IMS" accession="IMS:1000103" name="external array length" value="1581" />
-						<cvParam cvRef="IMS" accession="IMS:1000104" name="external encoded length" value="6324" />
+						<cvParam cvRef="IMS" accession="IMS:1000103" name="external array length" value="1567" />
+						<cvParam cvRef="IMS" accession="IMS:1000104" name="external encoded length" value="6268" />
 						<binary />
 					</binaryDataArray>
 					<binaryDataArray encodedLength="0">
 						<referenceableParamGroupRef ref="intensityArray" />
-						<cvParam cvRef="IMS" accession="IMS:1000102" name="external offset" value="37960" />
-						<cvParam cvRef="IMS" accession="IMS:1000103" name="external array length" value="1581" />
-						<cvParam cvRef="IMS" accession="IMS:1000104" name="external encoded length" value="6324" />
+						<cvParam cvRef="IMS" accession="IMS:1000102" name="external offset" value="37624" />
+						<cvParam cvRef="IMS" accession="IMS:1000103" name="external array length" value="1567" />
+						<cvParam cvRef="IMS" accession="IMS:1000104" name="external encoded length" value="6268" />
 						<binary />
 					</binaryDataArray>
 				</binaryDataArrayList>
@@ -260,15 +260,15 @@
 					<binaryDataArray encodedLength="0">
 						<referenceableParamGroupRef ref="mzArray" />
 						<cvParam cvRef="IMS" accession="IMS:1000102" name="external offset" value="16" />
-						<cvParam cvRef="IMS" accession="IMS:1000103" name="external array length" value="1581" />
-						<cvParam cvRef="IMS" accession="IMS:1000104" name="external encoded length" value="6324" />
+						<cvParam cvRef="IMS" accession="IMS:1000103" name="external array length" value="1567" />
+						<cvParam cvRef="IMS" accession="IMS:1000104" name="external encoded length" value="6268" />
 						<binary />
 					</binaryDataArray>
 					<binaryDataArray encodedLength="0">
 						<referenceableParamGroupRef ref="intensityArray" />
-						<cvParam cvRef="IMS" accession="IMS:1000102" name="external offset" value="44284" />
-						<cvParam cvRef="IMS" accession="IMS:1000103" name="external array length" value="1581" />
-						<cvParam cvRef="IMS" accession="IMS:1000104" name="external encoded length" value="6324" />
+						<cvParam cvRef="IMS" accession="IMS:1000102" name="external offset" value="43892" />
+						<cvParam cvRef="IMS" accession="IMS:1000103" name="external array length" value="1567" />
+						<cvParam cvRef="IMS" accession="IMS:1000104" name="external encoded length" value="6268" />
 						<binary />
 					</binaryDataArray>
 				</binaryDataArrayList>
@@ -289,15 +289,15 @@
 					<binaryDataArray encodedLength="0">
 						<referenceableParamGroupRef ref="mzArray" />
 						<cvParam cvRef="IMS" accession="IMS:1000102" name="external offset" value="16" />
-						<cvParam cvRef="IMS" accession="IMS:1000103" name="external array length" value="1581" />
-						<cvParam cvRef="IMS" accession="IMS:1000104" name="external encoded length" value="6324" />
+						<cvParam cvRef="IMS" accession="IMS:1000103" name="external array length" value="1567" />
+						<cvParam cvRef="IMS" accession="IMS:1000104" name="external encoded length" value="6268" />
 						<binary />
 					</binaryDataArray>
 					<binaryDataArray encodedLength="0">
 						<referenceableParamGroupRef ref="intensityArray" />
-						<cvParam cvRef="IMS" accession="IMS:1000102" name="external offset" value="50608" />
-						<cvParam cvRef="IMS" accession="IMS:1000103" name="external array length" value="1581" />
-						<cvParam cvRef="IMS" accession="IMS:1000104" name="external encoded length" value="6324" />
+						<cvParam cvRef="IMS" accession="IMS:1000102" name="external offset" value="50160" />
+						<cvParam cvRef="IMS" accession="IMS:1000103" name="external array length" value="1567" />
+						<cvParam cvRef="IMS" accession="IMS:1000104" name="external encoded length" value="6268" />
 						<binary />
 					</binaryDataArray>
 				</binaryDataArrayList>
@@ -318,15 +318,15 @@
 					<binaryDataArray encodedLength="0">
 						<referenceableParamGroupRef ref="mzArray" />
 						<cvParam cvRef="IMS" accession="IMS:1000102" name="external offset" value="16" />
-						<cvParam cvRef="IMS" accession="IMS:1000103" name="external array length" value="1581" />
-						<cvParam cvRef="IMS" accession="IMS:1000104" name="external encoded length" value="6324" />
+						<cvParam cvRef="IMS" accession="IMS:1000103" name="external array length" value="1567" />
+						<cvParam cvRef="IMS" accession="IMS:1000104" name="external encoded length" value="6268" />
 						<binary />
 					</binaryDataArray>
 					<binaryDataArray encodedLength="0">
 						<referenceableParamGroupRef ref="intensityArray" />
-						<cvParam cvRef="IMS" accession="IMS:1000102" name="external offset" value="56932" />
-						<cvParam cvRef="IMS" accession="IMS:1000103" name="external array length" value="1581" />
-						<cvParam cvRef="IMS" accession="IMS:1000104" name="external encoded length" value="6324" />
+						<cvParam cvRef="IMS" accession="IMS:1000102" name="external offset" value="56428" />
+						<cvParam cvRef="IMS" accession="IMS:1000103" name="external array length" value="1567" />
+						<cvParam cvRef="IMS" accession="IMS:1000104" name="external encoded length" value="6268" />
 						<binary />
 					</binaryDataArray>
 				</binaryDataArrayList>
--- a/test-data/preprocessing_results4.imzml.txt	Wed May 13 17:56:03 2020 +0000
+++ b/test-data/preprocessing_results4.imzml.txt	Tue Nov 03 22:41:21 2020 +0000
@@ -1,4 +1,4 @@
 imzML file:
 total 84
--rw-r--r-- 1 meli meli 63256 Mai 10 17:40 ibd
--rw-r--r-- 1 meli meli 18199 Mai 10 17:40 imzml
+-rw-rw-r-- 1 meli meli 62696 Oct  5 19:58 ibd
+-rw-rw-r-- 1 meli meli 18199 Oct  5 19:58 imzml
Binary file test-data/preprocessing_results4.pdf has changed
Binary file test-data/preprocessing_results5.ibd has changed
--- a/test-data/preprocessing_results5.imzml	Wed May 13 17:56:03 2020 +0000
+++ b/test-data/preprocessing_results5.imzml	Tue Nov 03 22:41:21 2020 +0000
@@ -9,8 +9,8 @@
 		<fileContent>
 			<cvParam cvRef="MS" accession="MS:1000579" name="MS1 spectrum" value="" />
 			<cvParam cvRef="MS" accession="MS:1000128" name="profile spectrum" value="" />
-			<cvParam cvRef="IMS" accession="IMS:1000080" name="universally unique identifier" value="3aff713c-00ec-422d-b63d-efd45fbdd7cc" />
-			<cvParam cvRef="IMS" accession="IMS:1000091" name="ibd SHA-1" value="9316138c1e7484662943bb206c79c2d074121530" />
+			<cvParam cvRef="IMS" accession="IMS:1000080" name="universally unique identifier" value="56965a72-6fd7-4879-bb80-b72cb3af4a62" />
+			<cvParam cvRef="IMS" accession="IMS:1000091" name="ibd SHA-1" value="5e07e272de044937cd6be7bfdbf2f4730aad10a9" />
 			<cvParam cvRef="IMS" accession="IMS:1000030" name="continuous" value="" />
 		</fileContent>
 	</fileDescription>
@@ -42,7 +42,7 @@
 		</sample>
 	</sampleList>
 	<softwareList count="1">
-		<software id="Cardinal" version="2.4.0">
+		<software id="Cardinal" version="2.6.0">
 			<cvParam cvRef="MS" accession="MS:1000799" name="custom unreleased software tool" value="" />
 		</software>
 	</softwareList>
--- a/test-data/preprocessing_results5.imzml.txt	Wed May 13 17:56:03 2020 +0000
+++ b/test-data/preprocessing_results5.imzml.txt	Tue Nov 03 22:41:21 2020 +0000
@@ -1,4 +1,4 @@
 imzML file:
 total 428
--rw-r--r-- 1 meli meli 415936 Mai 10 17:40 ibd
--rw-r--r-- 1 meli meli  18569 Mai 10 17:40 imzml
+-rw-rw-r-- 1 meli meli 415936 Oct  5 19:59 ibd
+-rw-rw-r-- 1 meli meli  18569 Oct  5 19:59 imzml
Binary file test-data/preprocessing_results5.pdf has changed
Binary file test-data/rdata_notfiltered.pdf has changed
Binary file test-data/test1.pdf has changed
Binary file test-data/test2.pdf has changed
Binary file test-data/test2.rdata has changed
Binary file test-data/test3.pdf has changed
Binary file test-data/test4.pdf has changed
Binary file test-data/test4.rdata has changed
Binary file test-data/test5.pdf has changed
Binary file test-data/test6.pdf has changed
Binary file test-data/test6.rdata has changed
Binary file test-data/test7.pdf has changed
Binary file test-data/test7.rdata has changed