---
title: "Golden Batch Comparison Viewer"
id: "golden-batch-comparison-viewer-1"
project: "MES User Manual"
url: "https://docs.sepasoft.com/articles/user-manual/golden-batch-comparison-viewer-1"
updated: 2026-12-01T00:47:04Z
---

# Golden Batch Comparison Viewer

#  Golden Batch Comparison Viewer Reference
 
[See: Using Golden Batch](/articles/user-manual/using-golden-batch)

The Golden Batch Comparison Viewer compares a completed target Batch with a completed golden Batch. It shows Golden value, target value, deviation, and tolerance, and opens value-change history and recorded process-value charts.

Find this component under the Ignition Designer Perspective Component Palette in the Batch category, named Golden Batch Comparison Viewer.

Component type: mes.batch.goldenBatchComparisonViewer

Both Batches must be complete and must share a Master Recipe identity. The same formula is not required. Idle steps are excluded. System parameters are included.

Until targetBatchID and either goldenBatchID or goldenBatchConfig are set, the viewer shows: Specify a Golden Batch ID or Golden Batch Configuration plus a target Batch ID to compare.
![Golden Batch Comparison Viewer. Golden values are green, differing target values are red, and the badge on Target Batch is the mismatch count. Blue Track Value buttons open history.](/resources/Storage/user-manual/Imported/golden-batch-comparison-viewer/img0001.png)
Golden Batch Comparison Viewer. Golden values are green, differing target values are red, and the badge on Target Batch is the mismatch count. Blue Track Value buttons open history.

##  Capabilities

| Capability | Description |
| --- | --- |
| Named standard | goldenBatchConfig alone uses that Configuration's Batch as the baseline and applies its include and tolerance policy. |
| Direct Batch IDs | goldenBatchID alone compares the two Batch IDs with recipe-default inclusion and tolerances. |
| Policy on another baseline | Set both. goldenBatchID is the baseline. The Configuration supplies the policy. The Configuration's anchored Batch must share that baseline's Master Recipe. |
| Mismatch list | Show only mismatched parameter values hides rows that matched. The badge on Target Batch is the mismatch count. |
| Value history | Track Value opens value-change history and, when a profile exists, the recorded process-value chart. |
| Export and print | Export downloads comparisonData\_&lt;timestamp&gt;.json. Print prints the current table. Print is hidden on a workstation session. Both are disabled while the table is loading, empty, or in error. |

##  How to use
 
###  Compare a finished Batch
 
* Bind targetBatchID to the Batch the operator selected. See [Batch Selector](/articles/user-manual/batch-selector).
* Bind one baseline:
    * goldenBatchConfig for a saved standard.
    * goldenBatchID for a one-off comparison against a completed Batch ID.
* Both when a saved policy should apply to a baseline other than the Configuration's own Batch.
* While the table loads, the viewer shows: Please wait while comparison data is loading…
* Golden values use the Golden color (default green). Target values that differ use the target color (default red). Highlight differences is on by default.
* The badge on Target Batch is the number of mismatched parameters.

| Column | Meaning |
| --- | --- |
| Name | Step or parameter. In Show flattened view the path is shown with the name. |
| Execution | Occurrence number when the same step ran more than once, or when the two Batches did not run it the same number of times. |
| Golden Batch | Baseline value, with engineering units when the recipe defines them. |
| Target Batch | Value from the Batch under review, with that Batch's engineering units. |
| Percent Deviation | Target change as a percent of the Golden value, when both are numeric. 84.5 against 78 shows as 8.33%. |
| Actual Deviation | Target minus Golden, when both are numeric. |
| Lower Tolerance / Upper Tolerance | Allowed band. A trailing % is relative. A number without % is absolute. |
| Action | Track Value when history or a process-value profile is available. |

| Control | What it does |
| --- | --- |
| Show only mismatched parameter values | Hides rows that matched. The viewer reloads the comparison when this box changes. |
| Show flattened view | Drops the step tree and lists parameters in one table. |
| Highlight differences | Colors Golden and differing target values. |
| Export | Downloads the current comparison as comparisonData\_&lt;timestamp&gt;.json. |
| Print | Prints the current table. Hidden on a workstation session. |

If every compared row matches, the table shows No differences to display.

If the Batches are not complete, do not share a Master Recipe, or the Configuration name cannot be resolved, the viewer shows An error occurred while getting comparison data. and Please try selecting another batch pair to compare.

###  When a row is a mismatch

* A numeric parameter with a tolerance is a mismatch when the target value falls outside that band. A different number that stays inside the band is a match.
* When both Batches recorded a process value, the row is also a mismatch if any target sample leaves the tolerance around the Golden curve at the same elapsed time. The row stays a mismatch when the final value has come back inside the band.
* A parameter with no tolerance, and any non-numeric parameter, is a mismatch when the values are not equal.
* A process value recorded on only one Batch is a mismatch.

Clear Show only mismatched parameter values to see rows that stayed inside the band. Track Value is on those rows once they are visible.

A curve that stayed inside the band is a match, even where the target is not identical to the Golden curve.
![Overlay chart of a run that stays inside the tolerance band. The target differs from the Golden curve and remains a match.](/resources/Storage/user-manual/Imported/golden-batch-comparison-viewer/img0002.png)
Overlay chart of a run that stays inside the tolerance band. The target differs from the Golden curve and remains a match.

comparisonColors replaces the default green, red, and out-of-tolerance colors in the table and on the chart.
![Comparison Viewer with custom colors. Golden values are blue, differing target values are orange, and the out-of-tolerance jacket temperature is yellow.](/resources/Storage/user-manual/Imported/golden-batch-comparison-viewer/img0003.png)
Comparison Viewer with custom colors. Golden values are blue, differing target values are orange, and the out-of-tolerance jacket temperature is yellow.

###  Review process-value history
 
Track Value opens Value History: followed by the parameter path. A grey button means there is nothing further to open. A blue button opens the dialog.

The dialog has three parts. They keep their size while data arrives.

* Value-change history pairs the Golden Batch's Nth value change with the target Batch's Nth value change. Columns are #, Golden Batch Value, Golden Batch Time, Target Batch Value, and Target Batch Time. If there is no history, the dialog says No value history is available for this parameter.
* Process-value chart, when either side has a recorded profile.
* Recorded Process Values and a status footer. The table appears after every requested side has finished paging. Until then the area shows Loading data…

![Value History for a state parameter. Each row pairs one Golden value change with the target value change at the same step.](/resources/Storage/user-manual/Imported/golden-batch-comparison-viewer/img0004.png)
Value History for a state parameter. Each row pairs one Golden value change with the target value change at the same step.

| Layout | What you see |
| --- | --- |
| Overlay | Both Batches on one chart. The Golden curve is the reference. A band around it is the tolerance. The target curve changes color where it leaves that band. |
| Side by side | Golden on the left, target on the right. Lock Y-axis keeps the same value scale on both. |
| Stacked | The two charts, one above the other. |

| Alignment | What it does |
| --- | --- |
| Since step start | Lines both profiles up from the moment each step execution began. |
| Since batch start | Places each profile where its step execution fell inside its own Batch. |
| By occurrence | Pairs Golden and target by occurrence number, the same pairing as the Recorded Process Values table. |

![Overlay chart. Both profiles share one time axis from the step start. The target turns red where it leaves the tolerance band.](/resources/Storage/user-manual/Imported/golden-batch-comparison-viewer/img0005.png)
Overlay chart. Both profiles share one time axis from the step start. The target turns red where it leaves the tolerance band.
![Side by side, with Lock Y-axis on and alignment By occurrence.](/resources/Storage/user-manual/Imported/golden-batch-comparison-viewer/img0006.png)
Side by side, with Lock Y-axis on and alignment By occurrence.
![Stacked, aligned Since batch start. The target step begins later in its own Batch, so its curve starts farther to the right.](/resources/Storage/user-manual/Imported/golden-batch-comparison-viewer/img0007.png)
Stacked, aligned Since batch start. The target step begins later in its own Batch, so its curve starts farther to the right.

Chart tools:

* Hover a point for Actual value, Elapsed time, Recorded at, and Change from previous.
* Click a point to focus it. Later tooltips include Change from focused. Clear focus drops the pinned point. If the focused point is outside the current zoom, the status says outside current view.
* Zoom: drag across the chart, use the mouse wheel, or use − / +. Hold Ctrl to temporarily use the other tool.
* Pan: drag horizontally through a zoomed range. Shift plus the mouse wheel also pans.
* Reset view and Full range return to the entire profile. After a zoom, Full range shows the visible interval. Click it to return to the full profile.
* Mini timeline drags a window through a long run.
* Hide In-Tolerance values keeps only out-of-tolerance samples in the Recorded Process Values table. The heading updates to Showing {shown} of {total} rows. If every row is hidden, the table says No out of tolerance values.

![Focused point on an overlay chart. Out-of-tolerance rows in the Recorded Process Values table are highlighted.](/resources/Storage/user-manual/Imported/golden-batch-comparison-viewer/img0008.png)
Focused point on an overlay chart. Out-of-tolerance rows in the Recorded Process Values table are highlighted.

The footer reports Loading with Golden {loaded}/{total} · Target {loaded}/{total}. When both sides finish it says Loaded and the point counts. A side that was never recorded shows an em dash.

If a page fails, the footer says Errored and Data could not be loaded. Press Retry to load again. Retry reloads only the failed side.

* A page that could not be read, did not continue the requested page, or repeated samples already loaded keeps the samples that were accepted. Retry asks for that same page again.
* A cursor that has expired, is not valid, or does not match the requested page cannot be used again. That side is cleared, and Retry starts it from the first page.
* If the stored profile changes while pages are loading, that side is cleared the same way.

The browser keeps up to 250,000 samples. Opening another large profile drops the oldest closed profile from that memory. The open dialog is kept. This does not show the error footer.

A time-weighted profile is labeled (time-weighted). When no tolerance is configured, the chart says No tolerance is configured for this parameter, so no band is shown. When a profile exists and contains no samples, it says No process values were recorded for this parameter.

Layout, alignment, Lock Y-axis, Combined tooltip, Mini timeline, and Hide In-Tolerance values are remembered in this browser.

###  Date, time, and numbers

| Place | How it is formatted |
| --- | --- |
| Comparison table date-times | dateTimeFormat, in the gateway's default locale and time zone. The default pattern is yyyy-MM-dd HH:mm:ss.SSS. An invalid pattern throws. |
| Comparison table numbers | Up to two fraction digits, with grouping turned off. |
| Value History Recorded At | The session locale and time zone. |
| Chart tooltip Recorded at | UTC, in ISO 8601. |
| Elapsed Time and the chart time axis | A duration, m:ss. When the span is one hour or longer, h:mm:ss. |
| Occurrence axis | # followed by the occurrence number. |
| Chart values | An integer is shown as-is. A fraction whose absolute value is below 10 uses two decimals. Any other fraction uses one decimal. |

##  Component Properties
 
Properties can be set in the Perspective Property Editor or through scripting. The section prefix is included before the property name (props, position, custom, or meta).

###  Example
 
viewer = self.getSibling("GoldenBatchComparisonViewer")

viewer.props.goldenBatchConfig = "Week 38 Standard"

viewer.props.targetBatchID = selectedBatchId

viewer.props.dateTimeFormat = "yyyy-MM-dd HH:mm:ss.SSS"

viewer.props.comparisonColors.goldenBatchBackgroundColor = "#dff3ff"

viewer.props.comparisonColors.goldenBatchTextColor = "#053047"

| Name | Scripting | Property Type | Description |
| --- | --- | --- | --- |
| Golden Batch ID | goldenBatchID | String | Completed Batch ID used as the baseline. Defaults to empty. |
| Golden Batch Config | goldenBatchConfig | String | Name of a Golden Batch Configuration. Supplies included parameters and tolerance overrides, and, when Golden Batch ID is empty, the baseline Batch. Defaults to empty. |
| Target Batch ID | targetBatchID | String | Completed Batch ID to review. Defaults to empty. |
| Date Time Format | dateTimeFormat | String | Format for date-times in the comparison, in the gateway's default locale and time zone. Defaults to yyyy-MM-dd HH:mm:ss.SSS. An invalid pattern throws. Examples: EEE, MMM d, yyyy h:mm a z, yyyy.MM.dd G 'at' HH:mm:ss z, YYYY-'W'ww-u. |
| Comparison Colors | comparisonColors | Object | Colors for Golden values, target values, and out-of-tolerance values. See Comparison Colors below. |
| Style | style | Style Object | Perspective style applied to the component. Refer to the Ignition Style Reference for classes, colors, fonts, and related settings. |
| Panel Style | panelStyle | Style Object | Style applied to the comparison panel. |
| Panel Title Style | panelTitleStyle | Style Object | Style applied to the panel title. |
| Table Style | tableStyle | Style Object | Style applied to the comparison table. |
| Table Header Style | tableHeaderStyle | Style Object | Style applied to the comparison table header. |
| Toolbar Style | toolbarStyle | Style Object | Style applied to the comparison toolbar. |
| Tooltip Style | tooltipStyle | Style Object | Style applied to tooltips. Defaults to backgroundColor rgba(97, 97, 97, 0.9), color #FFFFFF, fontSize 12px, and an empty classes string. |

###  Comparison Colors

| Name | Scripting | Property Type | Description |
| --- | --- | --- | --- |
| Golden Batch Background Color | comparisonColors.goldenBatchBackgroundColor | Color | Background for Golden Batch values. Defaults to #d4edda. |
| Golden Batch Text Color | comparisonColors.goldenBatchTextColor | Color | Text color for Golden Batch values. Defaults to #155724. |
| Target Batch Background Color | comparisonColors.targetBatchBackgroundColor | Color | Background for target Batch values. Defaults to #f8d7da. |
| Target Batch Text Color | comparisonColors.targetBatchTextColor | Color | Text color for target Batch values. Defaults to #721c24. |
| Out of Tolerance Background Color | comparisonColors.outOfToleranceBackgroundColor | Color | Background for out-of-tolerance values. Defaults to #f8d7da. |
| Out of Tolerance Text Color | comparisonColors.outOfToleranceTextColor | Color | Text color for out-of-tolerance values. Defaults to #721c24. |

This component does not define custom Perspective events. Bind the Batch ID and Configuration properties above. system.mes.batch.queue.getGoldenBatchComparison and getProcessValueProfile return the same comparison and profile pages to a script. See the Golden Batch Reference.
 © Sepasoft. All rights reserved. 
 [Send feedback](mailto:support@clickhelp.com) on this topic to Sepasoft.