# HG changeset patch
# User galaxyp
# Date 1511808575 18000
# Node ID 385e8a4accd99002bc45ca9cd3a16aec6c7bca77
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/msi_ion_images commit 6d271de132f364b1e16b0222ad2d6e315586f0dd
diff -r 000000000000 -r 385e8a4accd9 msi_ion_images.xml
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/msi_ion_images.xml Mon Nov 27 13:49:35 2017 -0500
@@ -0,0 +1,263 @@
+
+
+ mass spectrometry imaging heatmaps
+
+
+ bioconductor-cardinal
+ r-gridextra
+ r-kernsmooth
+ r-lattice
+
+
+
+
+
+ 0
+npeaks= sum(spectra(msidata)[]>0)
+## Spectra multiplied with mz (potential number of peaks)
+numpeaks = ncol(spectra(msidata)[])*nrow(spectra(msidata)[])
+## Percentage of intensities > 0
+percpeaks = round(npeaks/numpeaks*100, digits=2)
+## Number of empty TICs
+TICs = colSums(spectra(msidata)[])
+NumemptyTIC = sum(TICs == 0)
+
+## Processing informations
+processinginfo = processingData(msidata)
+centroidedinfo = processinginfo@centroided # TRUE or FALSE
+
+## if TRUE write processinginfo if no write FALSE
+
+## normalization
+if (length(processinginfo@normalization) == 0) {
+ normalizationinfo='FALSE'
+} else {
+ normalizationinfo=processinginfo@normalization
+}
+## smoothing
+if (length(processinginfo@smoothing) == 0) {
+ smoothinginfo='FALSE'
+} else {
+ smoothinginfo=processinginfo@smoothing
+}
+## baseline
+if (length(processinginfo@baselineReduction) == 0) {
+ baselinereductioninfo='FALSE'
+} else {
+ baselinereductioninfo=processinginfo@baselineReduction
+}
+## peak picking
+if (length(processinginfo@peakPicking) == 0) {
+ peakpickinginfo='FALSE'
+} else {
+ peakpickinginfo=processinginfo@peakPicking
+}
+
+### calculate how many input masses are valid:
+inputmasses = input_list[input_list[,1]>minmz & input_list[,1] 0",
+ "Number of zero TICs",
+ "Preprocessing",
+ "Normalization",
+ "Smoothing",
+ "Baseline reduction",
+ "Peak picking",
+ "Centroided",
+ paste0("# valid masses in ", "$filename"))
+
+values = c(paste0(maxfeatures),
+ paste0(minmz, " - ", maxmz),
+ paste0(pixelcount),
+ paste0(minimumx, " - ", maximumx),
+ paste0(minimumy, " - ", maximumy),
+ paste0(minint, " - ", maxint),
+ paste0(medint),
+ paste0(percpeaks, " %"),
+ paste0(NumemptyTIC),
+ paste0(" "),
+ paste0(normalizationinfo),
+ paste0(smoothinginfo),
+ paste0(baselinereductioninfo),
+ paste0(peakpickinginfo),
+ paste0(centroidedinfo),
+ paste0(length(inputmz), "/", length(input_list[,1])))
+
+property_df = data.frame(properties, values)
+
+######################################## PDF #############################################
+##########################################################################################
+##########################################################################################
+
+
+pdf("heatmaps.pdf", fonts = "Times", pointsize = 12)
+plot(0,type='n',axes=FALSE,ann=FALSE)
+#if not $filename:
+ #set $filename = $infile.display_name
+#end if
+title(main=paste("Quality control of MSI data\n\n", "Filename:", "$filename"))
+
+############################# I) numbers ####################################
+#############################################################################
+
+grid.table(property_df, rows= NULL)
+
+if (npeaks > 0)
+{
+ if (length(inputmz) != 0)
+ {
+ for (mass in 1:length(inputmz))
+ {
+ print(image(msidata, mz=inputmz[mass], strip = strip.custom(bg="lightgrey", par.strip.text=list(col="black", cex=.9)),
+ lattice=TRUE, ylim = c(maximumy+1,minimumy-1), plusminus = $plusminusinDalton, contrast.enhance = "histogram",
+ main= paste0(mass, ") ", inputnames[mass], " (", round(inputmz[mass], digits = 2)," ± ", $plusminusinDalton, " Da)")))
+ }
+ } else {print("The input masses were outside the mass range")}
+
+ dev.off()
+
+}else{
+ print("inputfile has no intensities > 0")
+dev.off()
+}
+ ]]>
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ `_
+- Analyze7.5 (upload hdr, img and t2m file via the "composite" function)
+- Cardinal "MSImageSet" data (with variable name "msidata", saved as .RData)
+
+The output of this tool contains heatmaps for every ion mass of interest as pdf.
+
+ ]]>
+
+
+ 10.1093/bioinformatics/btv146
+
+
diff -r 000000000000 -r 385e8a4accd9 test-data/Analyze75.hdr
Binary file test-data/Analyze75.hdr has changed
diff -r 000000000000 -r 385e8a4accd9 test-data/Analyze75.img
Binary file test-data/Analyze75.img has changed
diff -r 000000000000 -r 385e8a4accd9 test-data/Analyze75.t2m
Binary file test-data/Analyze75.t2m has changed
diff -r 000000000000 -r 385e8a4accd9 test-data/Example_Continuous.ibd
Binary file test-data/Example_Continuous.ibd has changed
diff -r 000000000000 -r 385e8a4accd9 test-data/Example_Continuous.imzML
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/test-data/Example_Continuous.imzML Mon Nov 27 13:49:35 2017 -0500
@@ -0,0 +1,373 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff -r 000000000000 -r 385e8a4accd9 test-data/Heatmaps_LM8_file16.pdf
Binary file test-data/Heatmaps_LM8_file16.pdf has changed
diff -r 000000000000 -r 385e8a4accd9 test-data/Heatmaps_analyze75.pdf
Binary file test-data/Heatmaps_analyze75.pdf has changed
diff -r 000000000000 -r 385e8a4accd9 test-data/Heatmaps_imzml.pdf
Binary file test-data/Heatmaps_imzml.pdf has changed
diff -r 000000000000 -r 385e8a4accd9 test-data/Heatmaps_rdata.pdf
Binary file test-data/Heatmaps_rdata.pdf has changed
diff -r 000000000000 -r 385e8a4accd9 test-data/LM8_file16.rdata
Binary file test-data/LM8_file16.rdata has changed
diff -r 000000000000 -r 385e8a4accd9 test-data/inputpeptides.csv
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/test-data/inputpeptides.csv Mon Nov 27 13:49:35 2017 -0500
@@ -0,0 +1,3 @@
+152 mass1
+328.9 mass2
+185.2 mass3
diff -r 000000000000 -r 385e8a4accd9 test-data/inputpeptides.txt
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/test-data/inputpeptides.txt Mon Nov 27 13:49:35 2017 -0500
@@ -0,0 +1,3 @@
+854.5
+1296.7
+2000.8
diff -r 000000000000 -r 385e8a4accd9 test-data/preprocessing_results1.RData
Binary file test-data/preprocessing_results1.RData has changed