Skip to main content

Trend and Trend Table objects

The Trend object puts a complete trend on a page: the pens you choose in the design, a toolbar, a date-time bar, a legend, a value table and a status bar. The Trend Table object shows the same values as rows of a table.

Before you begin​

  • The page is open in the screen editor.
  • The signals are recorded in an archive table; see Archive tables and assignments. Both objects read the history and add the live values as they arrive.

Steps​

1. Place a trend​

In WIDGETS, click Trend and draw a rectangle on the page. PROPERTIES shows the groups DATA, TIME, APPEARANCE and RUN. In the editor the object does not respond to the mouse; its buttons work on the run screen.

A new Trend object on the page and the DATA and TIME groups in PROPERTIES.

All fields with their defaults are listed in Trend.

2. Add the pens​

Expand Pens and click + Add pen for each signal. Click — select tag — to choose the signal in the signal picker.

Pens list with the first pen bound to T101.Level, its label, color, drawing lists and the limit boxes.
FieldMeaning
Label (empty = signal name)The name in the legend and in the tables
ColorThe color of the line
PlotLinear, Stepped or Points
Text DecorationThe line type: Solid, Dashed or Dotted
Width1, 1.5, 2, 3 or 4
DecimalDecimals of the value, 0 to 10. Empty is automatic.
Y scaleAutomatic from the data, or Manual with Minimum and Maximum
Hidden initiallyThe pen is in the legend, but its line is off when the page opens
Last value labelThe label with the last value at the end of the line
Axis nameThe signal name above its value axis

3. Add reference lines, limits and a fixed value​

Each pen can carry three kinds of horizontal line:

LineHow to add itHow it looks
Reference lineIn Reference lines: 8.5=H; 9.5=Max, type value=label, several separated by ;Dashed, with its label and value. It is always drawn.
Alarm limitUnder Limits, tick LL, L, H or HHDotted, with its level and value. Parts of the line beyond the limit are red.
Fixed valueClick + Add fixed value and type the value and the unitA separate pen on the axis of the first signal, with its own entry in the legend and the tables

The alarm limits come from the alarm levels of the signal. YTCC names them by their value: the nearest high limit is H, the next one HH, the nearest low limit L, the next one LL. Alarm limits under APPEARANCE turns all limit lines on or off. With a Manual scale, a line outside the scale is not drawn.

First pen with Reference lines 60=Target and the boxes LL, L, H and HH ticked.

4. Set the time and the appearance​

Under TIME, Time mode is Live (last N minutes) with Live duration (min), or Fixed range with Start and End. Trends and tables with the same Sync group share the time range, the pens and the ruler.

TIME group with Time mode Live (last N minutes), Live duration (min) 1440 and Sync group.
Under APPEARANCEEffect
Y axisOne axis per pen (side by side) or One axis per unit
Toolbar, Date-time bar, Show Legend, Status barShow or hide these parts
Ruler tableOpens the value table when the page opens
Minor gridFiner grid lines
Value axis on the right tooA copy of the first axis on the right side
Last value at the end of the lineThe labels of step 2 for the whole object
AppearanceStarts as Chart, Table or Chart and table stacked. Table ratio (stacked) is the share of the table, 0.2 to 0.8.
Min / max bandShaded band with the lowest and highest value of each interval
Plot area background, Grid colorEmpty follows the theme

Under RUN, Pen editing at runtime lets the operator add and remove pens and change their color and scale.

5. Read the trend on the run screen​

Save the page and open it on the run screen. The chart shows the history of the range and follows the live values. Click an entry in the legend to hide or show its line.

Trend on the run screen with the level and flow lines over 24 hours, limit lines, a reference line, a fixed value and last value labels.
Toolbar buttonEffect
Y axisThe axis menu, see step 8
ConfigurationThe configuration window, see step 9
First dataJumps 30 days back, with the same range length
Previous range, Next rangeMoves by one range. Next range is off while the trend is live.
Latest dataBack to now, live
Zoom to areaDrag over the chart to zoom into that area
PanDrag the chart to move in time. Dragging works in the normal mode too.
Zoom in, Zoom outHalves or doubles the range
Undo zoomOne zoom back. Backspace does the same.
Original viewThe time range of the design
Default viewTime range, zoom, ruler, statistics, axis layout, view and value table as in the design. The pens stay.
Reset vertical scaleSee step 7
Stop, StartStop freezes the display while recording continues. Start returns to now.
Ruler, Statistics area, Value tableSee step 10
ExportSee step 13
Chart, Table, Chart and table stackedSee step 11
White background, Hide top barsSee step 12

The status bar shows Ready, Loading…, Stopped, Historian (a fixed range) or Data could not be retrieved with the number of pens. It also shows the range, the connection dot and the clock. The chart marks a value of uncertain quality with ▲ and of bad quality with ◆.

6. Move in time​

The date-time bar has the live ranges 5 min, 15 min, 30 min, 1 h, 8 h, 24 h and 7 days. To show a fixed range, change Start and End and click Apply or press Enter. The fields use the date format of the interface language and turn red when the text is not a valid date. The indicator at the end shows Live, Stopped or Historian.

The mouse wheel over the chart zooms in time. Zooming or dragging leaves the live mode; Latest data or Start goes back.

Date-time bar with the range buttons, 8 h selected, Start, End, Apply and the Live indicator.

7. Move and scale the vertical axis​

ToDo this
Move all axesDrag the chart up or down
Move one axisDrag on that axis
Scale one axisTurn the wheel on that axis. The value under the mouse stays in place.
Move or scale all axesDo the same on the axis on the right

Reset vertical scale is active after such a change and restores the scale. Changing the axis layout or the number of pens restores it too.

Trend with a moved and scaled vertical axis and the mouse on the active Reset vertical scale button.

8. Use the axis menu​

Click Y axis in the toolbar. One axis per pen (side by side) gives each pen its own axis on the left, One axis per unit puts pens with the same unit on one axis, and Show value axes hides or shows the axes for a wider chart.

Open Y axis menu with One axis per pen (side by side), One axis per unit and Show value axes.

9. Change the pens in the configuration window​

Click Configuration. The Trend configuration window opens over the object. Drag its title to move it so that the chart stays visible; a click outside the window closes it. Each pen has a row, and a change applies at once:

ColumnContent
Visible, ColorShow or hide the line, its color
ItemThe name of the pen; for a fixed value the value and the unit
Width, Plot, Text DecorationAs in step 2
LabelThe last value label
Axis nameThe signal name above the axis
Y scale, Minimum, MaximumAutomatic or Manual with the range
DecimalDecimals of the value
LL, L, H, HHShows the alarm limit on the chart. A limit the signal does not have shows a dash.

Search in Search signal (min. 2 letters) and click a result to add a pen. The trash icon (Subtract) removes a pen. Add fixed value adds a line at the last value of the first signal. Back to design discards the changes.

The changes are kept in this browser for this object. They are discarded when the pens of the design change. With Pen editing at runtime off, the window only shows or hides pens.

Trend configuration window moved aside over the trend, with a row for each pen, Add fixed value, Back to design and the signal search.

10. Measure with the ruler and the statistics area​

Value table opens the table under the chart. It shows Item, Last value time, Value, Quality and Unit for each pen.

With Ruler, click or drag on the chart: the column changes to Ruler time and the table shows the values at that moment. With Statistics area, click the start and then the end of an interval. The table adds Minimum, Maximum, Average, ∫ ·h (the time-weighted integral, so flow gives volume and power gives energy) and Sample count. Clear removes the area. Esc leaves these modes.

Trend with a marked statistics area and the value table with Minimum, Maximum, Average, the integral and Sample count.

11. Switch between chart and table​

Chart, Table and Chart and table stacked show the same data and the same range. The table has one row per time with the newest row on top.

Trend in the stacked view with the chart on top and the rows of the table below.

12. Hide the top bars and change the background​

Hide top bars removes the toolbar and the date-time bar for a larger chart. The small Show top bars button at the top right of the chart brings them back.

The sun button changes the background. The object starts transparent, on the color of the screen, and the button is called White background. After a click it is white with Plot area background applied, and the button is called Screen-color background.

Trend without the top bars, with the small Show top bars button at the top right of the chart.

13. Export the data​

Click Export and choose Excel (.xlsx), CSV (.csv), HTML report (.html) or Image (.png). The file holds the visible range. YTCC asks where to save the file; a browser without this dialog downloads it to the download folder and a message says so.

Export menu of the trend with Excel, CSV, HTML report and Image.

14. Show the values in a Trend Table​

In WIDGETS, click Trend Table and draw a rectangle. Add pens as in step 2, or set the same Sync group as a trend: the table then uses the pens of the trend, its time range and its ruler. All fields are listed in Trend Table.

The table has a row number, Date and time with milliseconds, and a column for each pen. A value of bad quality is faded with ◆, a value of uncertain quality has ▲, and a value beyond an alarm limit of the signal is red. The table follows the newest row until you scroll away. The ruler of the trend scrolls the table to the nearest row and highlights it.

PropertyDefaultEffect
Live duration (min)15The range in Live (last N minutes) mode
Font size12Text size of the table
Last value in empty cellOnA cell without a sample repeats the last value of the pen
Newest firstOffThe newest row on top

Its toolbar has the time buttons, Stop, Export without the image format, and the background button. The status bar shows Line with the selected row and the number of rows.

Page with a Trend and a Trend Table in the same sync group, the ruler on the chart and the matching row highlighted in the table.

Next steps​