Repository 'proteomiqon_psmstatistics'
hg clone https://toolshed.g2.bx.psu.edu/repos/galaxyp/proteomiqon_psmstatistics

Changeset 0:b8590dea5e2d (2021-07-18)
Next changeset 1:f831f7d721f8 (2021-08-27)
Commit message:
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/proteomiqon_psmstatistics commit 7e7a2e71b21a1c92ae0c79cc4e25a7c2a5f0c4f1"
added:
proteomiqon_psmstatistics.xml
static/images/SemiSupervisedScoring.png
test-data/result_1.json
test-data/result_2.json
test-data/result_3.json
test-data/sample.db
test-data/sample.psm
b
diff -r 000000000000 -r b8590dea5e2d proteomiqon_psmstatistics.xml
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/proteomiqon_psmstatistics.xml Sun Jul 18 13:53:08 2021 +0000
[
b'@@ -0,0 +1,175 @@\n+<tool id="proteomiqon_psmstatistics" name="ProteomIQon PSMStatistics" version="@VERSION@" profile="20.05">\n+    <description>\n+        utilizes semi supervised machine learning techniques to integrate search engine scores as well as the mentioned quality scores into one single consensus score.\n+    </description>\n+    <macros>\n+        <token name="@VERSION@">0.0.6</token>\n+    </macros>\n+    <requirements>\n+        <requirement type="package" version="@VERSION@">proteomiqon-psmstatistics</requirement>\n+    </requirements>\n+    <command detect_errors="exit_code"><![CDATA[\n+        #import re\n+        #set basename = $re.sub(r\'[^\\w ,.\\-+]\',\'_\', $psm.element_identifier)\n+        #if $outputParamfile:\n+            cat \'$paramfile\' >> \'$out_paramfile\' &&\n+        #end if\n+        ln -s \'$psm\' \'${basename}.psm\' &&\n+        ln -s \'$out_qpsm\' \'${basename}.qpsm\' &&\n+        proteomiqon-psmstatistics -i \'./${basename}.psm\' -d \'$peptideDB\' -p \'$paramfile\' -o ./\n+    ]]>\n+    </command>\n+    <configfiles>\n+        <configfile name="paramfile">\n+            <![CDATA[\n+            {\n+                "Threshold":\n+                {\n+                    #if $ThresholdCond.ProcessingType == "Estimate"\n+                    "Case":"Estimate",\n+                    "Fields":\n+                    [\n+                        {\n+                            "QValueThreshold" : $ThresholdCond.QValueThreshold,\n+                            "PepValueThreshold" : $ThresholdCond.PepValueThreshold,\n+                            "MaxIterations" : $ThresholdCond.MaxIterations,\n+                            "MinimumIncreaseBetweenIterations" : $ThresholdCond.MinimumIncreaseBetweenIterations,\n+                            "PepValueFittingMethod" : {\n+                                "Case":"$ThresholdCond.PepValueFittingMethod"\n+                            }\n+                        }\n+                    ]\n+                    #else if $ThresholdCond.ProcessingType == "Fixed"\n+                    "Case":"Fixed",\n+                    "Fields":\n+                    [\n+                        {\n+                            "SequestLike":$ThresholdCond.SequestLike,\n+                            "Andromeda":$ThresholdCond.Andromeda\n+                        }\n+                    ]\n+                    #end if\n+                },\n+                "ParseProteinIDRegexPattern":"${ParseProteinIDRegexPattern}",\n+                "KeepTemporaryFiles":false\n+            }\n+            ]]>\n+        </configfile>\n+    </configfiles>\n+    <inputs>\n+        <param name="psm" type="data" format="tabular" label="PSM" help="Specify list of peptide spectrum matches to be scored."/>\n+        <param name="peptideDB" type="data" format="sqlite" label="Peptide database" help="Specify the peptide data base."/>\n+        <conditional name="ThresholdCond">\n+            <param name="ProcessingType" type="select" label="Processing type" help="Specify how PSM thresholds should be estimated using semi supervised machine learning techniques (recommended) or if fixed score values should be used instead.">\n+                <option value="Estimate" selected="true">Estimate</option>\n+                <option value="Fixed">Fixed</option>\n+            </param>\n+            <when value="Estimate">\n+                <param name="QValueThreshold" type="float" value="0.01" label="Q-Value threshold" />\n+                <param name="PepValueThreshold" type="float" value="0.05" label="Pep-Value threshold" />\n+                <param name="MaxIterations" type="integer" value="15" label="Max iterations" />\n+                <param name="MinimumIncreaseBetweenIterations" type="float" value="0.005" label="Minimum increase between iterations" />\n+                <param name="PepValueFittingMethod" type="select" label="Pep-Value fitting method">\n+                    <option value="LinearSpline">Linear Spline</option>\n+                    <option value="LogisticRegressionLogit" selected="true">Logistic '..b'am name="peptideDB" value="sample.db"/>\n+            <param name="ParseProteinIDRegexPattern" value="id"/>\n+            <param name="outputParamfile" value="true"/>\n+            <conditional name="ThresholdCond">\n+                <param name="ProcessingType" value="Estimate"/>\n+                <param name="QValueThreshold" value="0.01"/>\n+                <param name="PepValueThreshold" value="0.05"/>\n+                <param name="MaxIterations" value="15"/>\n+                <param name="MinimumIncreaseBetweenIterations" value="0.005"/>\n+                <param name="PepValueFittingMethod" value="LinearSpline"/>\n+            </conditional>\n+            <output name="out_paramfile" file="result_1.json"/>\n+        </test>\n+        <test expect_num_outputs="2">\n+            <param name="psm" value="sample.psm"/>\n+            <param name="peptideDB" value="sample.db"/>\n+            <param name="ParseProteinIDRegexPattern" value="id"/>\n+            <param name="outputParamfile" value="true"/>\n+            <conditional name="ThresholdCond">\n+                <param name="ProcessingType" value="Estimate"/>\n+                <param name="QValueThreshold" value="0.01"/>\n+                <param name="PepValueThreshold" value="0.05"/>\n+                <param name="MaxIterations" value="15"/>\n+                <param name="MinimumIncreaseBetweenIterations" value="0.005"/>\n+                <param name="PepValueFittingMethod" value="LogisticRegressionLogit"/>\n+            </conditional>\n+            <output name="out_paramfile" file="result_2.json"/>\n+        </test>\n+        <test expect_num_outputs="2">\n+            <param name="psm" value="sample.psm"/>\n+            <param name="peptideDB" value="sample.db"/>\n+            <param name="ParseProteinIDRegexPattern" value="id"/>\n+            <param name="outputParamfile" value="true"/>\n+            <conditional name="ThresholdCond">\n+                <param name="ProcessingType" value="Fixed"/>\n+                <param name="SequestLike" value="5.0"/>\n+                <param name="Andromeda" value="40.0"/>\n+            </conditional>\n+            <output name="out_paramfile" file="result_3.json"/>\n+        </test>\n+    </tests>\n+    <help>\n+    <![CDATA[\n+What It Does\n+------------\n+**Disclaimer** Disclaimer this tool needs a `peptide database <https://csbiology.github.io/ProteomIQon/tools/PeptideDB.html>`_ and `peptide spectrum matches <https://csbiology.github.io/ProteomIQon/tools/PeptideSpectrumMatching.html>`_.\n+\n+An established method to identify acquired MS/MS spectra is the comparison of each spectrum with peptides in a reference database.\n+\n+To measure the similarity of in silico generated spectra and measured MS/MS scans we use our own implementations of three established search enginge scores: SEQUEST, Andromeda and XTandem. \n+Additionally, we also record quality control parameters such as the mass difference between the precursor ion and the theoretically calulated mass or the uniquness of each score in comparison to \'competing\' peptides within the search space. \n+The PSMStatistics tool utilizes semi supervised machine learning techniques to integrate search engine scores as well as the mentioned quality scores into one single consensus score.\n+\n+.. image:: SemiSupervisedScoring.png\n+            :width: 768pt\n+            :height: 345pt\n+\n+Since the search space is extended by so called decoys - reversed counterparts of peptides within the search space - we can estimate the distribution of \'true negatives\' and calculate local (PEP values) and global (Q values) false discovery rates at each consensus score. \n+The reported peptides at user defined local and global FDR cutoffs can then be used as inputs for any downstream analysis be it ProteinInference or PSMBasedQuantification.\n+\n+Further Reading\n+---------------\n+Additional information about the tool can be found in the `documentation <https://csbiology.github.io/ProteomIQon/tools/PSMStatistics.html>`_.  \n+    ]]>\n+    </help>\n+</tool>\n'
b
diff -r 000000000000 -r b8590dea5e2d static/images/SemiSupervisedScoring.png
b
Binary file static/images/SemiSupervisedScoring.png has changed
b
diff -r 000000000000 -r b8590dea5e2d test-data/result_1.json
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/test-data/result_1.json Sun Jul 18 13:53:08 2021 +0000
[
@@ -0,0 +1,24 @@
+
+            
+            {
+                "Threshold":
+                {
+                    "Case":"Estimate",
+                    "Fields":
+                    [
+                        {
+                            "QValueThreshold" : 0.01,
+                            "PepValueThreshold" : 0.05,
+                            "MaxIterations" : 15,
+                            "MinimumIncreaseBetweenIterations" : 0.005,
+                            "PepValueFittingMethod" : {
+                                "Case":"LinearSpline"
+                            }
+                        }
+                    ]
+                },
+                "ParseProteinIDRegexPattern":"id",
+                "KeepTemporaryFiles":false
+            }
+            
+        
\ No newline at end of file
b
diff -r 000000000000 -r b8590dea5e2d test-data/result_2.json
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/test-data/result_2.json Sun Jul 18 13:53:08 2021 +0000
[
@@ -0,0 +1,24 @@
+
+            
+            {
+                "Threshold":
+                {
+                    "Case":"Estimate",
+                    "Fields":
+                    [
+                        {
+                            "QValueThreshold" : 0.01,
+                            "PepValueThreshold" : 0.05,
+                            "MaxIterations" : 15,
+                            "MinimumIncreaseBetweenIterations" : 0.005,
+                            "PepValueFittingMethod" : {
+                                "Case":"LogisticRegressionLogit"
+                            }
+                        }
+                    ]
+                },
+                "ParseProteinIDRegexPattern":"id",
+                "KeepTemporaryFiles":false
+            }
+            
+        
\ No newline at end of file
b
diff -r 000000000000 -r b8590dea5e2d test-data/result_3.json
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/test-data/result_3.json Sun Jul 18 13:53:08 2021 +0000
[
@@ -0,0 +1,19 @@
+
+            
+            {
+                "Threshold":
+                {
+                    "Case":"Fixed",
+                    "Fields":
+                    [
+                        {
+                            "SequestLike":5.0,
+                            "Andromeda":40.0
+                        }
+                    ]
+                },
+                "ParseProteinIDRegexPattern":"id",
+                "KeepTemporaryFiles":false
+            }
+            
+        
\ No newline at end of file
b
diff -r 000000000000 -r b8590dea5e2d test-data/sample.db
b
Binary file test-data/sample.db has changed
b
diff -r 000000000000 -r b8590dea5e2d test-data/sample.psm
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/test-data/sample.psm Sun Jul 18 13:53:08 2021 +0000
b
@@ -0,0 +1,7 @@
+PSMId GlobalMod PepSequenceID ModSequenceID Label ScanNr ScanTime Charge PrecursorMZ TheoMass AbsDeltaMass PeptideLength MissCleavages SequestScore SequestNormDeltaBestToRest SequestNormDeltaNext AndroScore AndroNormDeltaBestToRest AndroNormDeltaNext XtandemScore XtandemNormDeltaBestToRest XtandemNormDeltaNext StringSequence
+sample=1-period=1-cycle=2033-experiment=4_0_2_0 1 4 8 -1 0 32.9949 2 383.2268582 764.4508194 0.01165603632 7 -1 2.780764976 0.6779896705 0.0 26.3150871 0.7657267969 0.0 20.14279733 0.5594493789 0.0 ILVGDIK
+sample=1-period=1-cycle=2033-experiment=4_0_2_0 1 4 8 1 0 32.9949 2 383.2268582 764.4508194 0.01165603632 7 -1 8.635639049 0.0 0.6779896705 112.3264921 0.0 0.7657267969 45.72186797 0.0 0.5594493789 ILVGDIK
+sample=1-period=1-cycle=2043-experiment=5_2_2_0 0 22 87 -1 2 33.36088333 2 399.242789 796.4806883 0.009663316474 7 -1 1.412423849 0.8192994029 0.0 0.0 1.0 0.0 7.323219744 0.7506817907 0.0 ALEVIPR
+sample=1-period=1-cycle=2043-experiment=5_2_2_0 0 22 87 1 2 33.36088333 2 399.242789 796.4806883 0.009663316474 7 -1 7.816376209 0.0 0.8192994029 74.99645487 0.0 1.0 29.37298389 0.0 0.7506817907 ALEVIPR
+sample=1-period=1-cycle=2038-experiment=7_1_2_0 1 22 88 -1 1 33.18005 2 404.2288055 806.4510372 0.007979227388 7 -1 1.589227453 0.7970537368 0.0 11.5896755 0.8973792939 0.0 18.85459139 0.6070363597 0.0 ALEVIPR
+sample=1-period=1-cycle=2038-experiment=7_1_2_0 1 22 88 1 1 33.18005 2 404.2288055 806.4510372 0.007979227388 7 -1 7.830779576 0.0 0.7970537368 112.937008 0.0 0.8973792939 47.98049859 0.0 0.6070363597 ALEVIPR