Custom Metric - Peptide ID Count

Custom Metric - Peptide IDs
In this example we will create a run-scoped custom metric to track peptide ID counts. This involves the following:

Add an annotation in the Skyline document

The steps below will add a replicate-level annotation in the Skyline document that can be used to capture the peptide ID counts for each run imported into the document.
  • Open Document Settings from the Settings > Document Settings menu.
  • Select the Annotations tab and click the Add button to add a new annotation.
  • In the Define Annotation dialog:
    • Enter "PeptideCount" in the Name field.
    • Choose Number from the Type drop-down menu.
    • In the Applies to field, check Replicates.
  • Click OK.
  • The new annotation should be checked in the Annotations tab of the Document Settings dialog.
  • Click OK.

Populate the values for the new annotation in the Document Grid:
  • Open the Document Grid from the View > Document Grid menu .
  • Select Replicates from the Reports drop-down menu in the top left-corner of the Document Grid.
  • Fill the values in the "PeptideCount" column.

Upload the document to a Panorama QC folder. If you are using AutoQC Loader to upload results to Panorama, a new run will get imported into the document and automatically uploaded to Panorama before the value of the "PeptideCount" annotation can be added for the run. In this case the annotation value can be added later, and the document can either be uploaded manually to the Panorama server, or one can wait for the next time AutoQC Loader uploads to Panorama (when the next new run is acquired).

Create a query in Panorama

The steps below will add a query in the Panorama folder that will return the values of the "PeptideCount" annotation for each replicate in the Skyline documents uploaded to the folder.
  • From the Admin menu ( gear icon in the top right corner) select Go To Module > Query.
  • In the left panel of the Query Schema Browser select the targetedms schema.
  • Click the Create New Query button at the top of the query schema browser.
  • In the New Query form enter a name for the query (e.g. QCRunMetric_peptideCount) and click the Create and Edit Source button.
  • Delete the existing SQL in the textfield, and enter the SQL below.

0 AS PrecursorChromInfoId,
Id AS SampleFileId,
'PeptideCount' AS SeriesLabel,
-- Replicate-level annotations from Skyline documents get saved in the ReplicateAnnotation table. The 'Name' column has the name of the annotation.
CAST ((SELECT ra.Value FROM ReplicateAnnotation ra WHERE ra.ReplicateId = sf.ReplicateId AND ra.Name = 'PeptideCount') AS INTEGER) AS MetricValue
FROM SampleFile sf
  • Click Save and Finish

View the documentation for creating queries for custom metrics here: Define Custom Metrics

Create a custom metric

  • Go the Panorama Dashboard.
  • Click the triangle in the top right corner of the QC Plots panel to view the drop-down menu.
  • Select Configure QC Metrics.
  • Click the Add New Custom Metric button.
  • In the Add New Metric form:
    • Enter "Peptide ID Count" in the Name field.
    • Choose targetedms from the Series 1 Schema drop-down menu.
    • Choose the new query, "QCRunMetric_peptideCount" created in the previous section, from the Series 1 Query drop-down menu.
    • Enter "Peptide ID Count" in the Series 1 Axis Label field.
    • Choose Run from the Metric Type drop-down menu.
  • Click Save.

Go to the Panorama Dashboard. "Peptide ID Count" should now be available in the Metric drop-down menu.

Complete documentation for configuring metrics in a Panorama QC folder can be found here: Panorama: Configure QC Metrics