Skip to main content

Chart

Chart ctrlName [ keyword = value [, keyword = value ...] ]

The Chart operation creates or modifies a chart control. Charts are generally used in conjunction with data acquisition. Charts do not have to be connected to a FIFO, but they are not useful until they are.

For information about the state or status of the control, use the ControlInfo operation.

Parameters

ctrlName is the name of the Chart to be created or changed.

align=alignmentSets the alignment mode of the control. The alignment mode controls the interpretation of the leftOrRight parameter to the pos keyword. The align keyword was added in Igor Pro 8.00.
If alignment=0 (default), leftOrRight specifies the position of the left end of the control and the left end position remains fixed if the control size is changed.
If alignment=1, leftOrRight specifies the position of the right end of the control and the right end position remains fixed if the control size is changed.
chans={ch#, ch#,...}List of FIFO channel numbers that Chart is to monitor.
color(ch# )=(r,g,b[,a])
Sets the color of the specified trace. r, g, b, and a specify the the color and optional opacity as RGBA Values.
ctab=colortableNameWhen a channel is connected to an image strip FIFO channel, the data is displayed as an image using this built-in color table. Valid names are the same as used in images. Invalid name will result in the default Grays color table being used.
disable=dSets user editability of the control.
d=0:Normal.
d=1:Hide.
d=2:Disable user input. Charts do not change appearance because they are read-only. When disabled, the hand cursor is not shown.
d=3:Hide and disable the control. This is useful to disable a control that is also hidden because it is in a hidden tab.
fbkRGB=(r,g,b[,a])Sets frame background color. r, g, b, and a specify the the color and optional opacity as RGBA Values.
fgRGB=(r,g,b[,a])Sets foreground color (text etc.). r, g, b, and a specify the the color and optional opacity as RGBA Values.
fifo=FIFONameSets FIFO that chart will monitor.
font="fontName"Sets chart's font, e.g., font="Helvetica".
fsize=sSets font size for chart.
fstyle=fsSpecifies the font style. fs is a bitwise parameter with each bit controlling one aspect of the font style as follows:
Bit 0:Bold
Bit 1:Italic
Bit 2:Underline
Bit 4:Strikethrough
See Setting Bit Parameters for details about bit settings.
gain(ch# )=gSets the display gain of the specified channel relative to nominal. Values greater than unity expand the display.
gridRGB=(r,g,b[,a])Sets grid color. r, g, b, and a specify the the color and optional opacity as RGBA Values.
guides={left, hcenter, right, top, vcenter, bottom}
Controls attachments of anchor points to layout guides. See Laying Out Controls in Guides Mode for detailed information and examples.
Each of left, hcenter, right, top, vcenter, bottom is replaced with the name of a layout guide of appropriate orientation. That is, left, hcenter, right indicate attachments to vertical guides, and top, vcenter, bottom indicate attachments to horizontal guides. Use the special name kwNone to represent an unattached anchor point.
An error results if you overconstrain a control's layout. Of the three horizontal or vertical anchor points, at most two may be attached to layout guides. Attaching one of the three causes a control to move as the layout guide moves. Attaching two causes a control to both move and resize. Thus, the name kwNone will appear at least twice.
Using kwNone for all anchor points results in completely detaching a control from the layout guides.
help={helpStr }Sets the help for the control.
helpStr is limited to 1970 bytes (255 in Igor Pro 8 and before).
You can insert a line break by putting "\r" in a quoted string.
jumpTo=pChart jumps to point number p. This works in review mode only.
lineMode(ch# )=lmSet the display line mode for the given channel.
lm =0:Dots mode. Draws values as dots. However, if the number of dots in a strip exceeds maxDots then Igor draws a vertical line from the min to the max of the values packed into the strip.
lm =1:Lines mode. Draws a vertical line encompassing the min and the max of the points in a given strip along with the last point of the preceding strip. Since which strip is the preceding strip depends on the direction of motion then the appearance may slightly shift depending on which direction the chart is moving.
lm =2:Sticks to zero mode. Draws a vertical line encompassing the min and the max of the points in a given strip along with a value of zero.
mass=mSets the feel of the chart paper when you move it with the mouse. The larger the mass m, the slower the chart recorder responds. Odd values cause the movement of the paper to stop the instant the mouse is clicked while even values continue with the illusion of mass.
maxDots=mdControls whether points in a given vertical strip of the chart are displayed as dots or as a solid line. See lineMode above. Default is 20.
offset(ch# )=oSets the display offset of the specified channel. The offset value is subtracted from the data before the gain is applied.
oMode=omChart operation mode.
om =0:Live mode.
om =1:Review mode.
pbkRGB=(r,g,b[,a])Sets plot area background color. r, g, b, and a specify the the color and optional opacity as RGBA Values.
pos={leftOrRight,top }Sets the position in control panel units of the top/left corner of the control if its alignment mode is 0 or the top/right corner of the control if its alignment mode is 1. See the align keyword above for details.
ppStrip=ppsNumber of data points packed into each vertical strip of the chart.
rename=newNameGives the control a new name.
rSize(ch# )=rsSets the relative vertical size allocated to the given channel. Nominal is unity. If the value of rs is zero then this channel shares space with the previous channel.
sMode=smStatus line mode.
sm =0:Turns off fancy status line and positioning bar.
sm =1:Normal mode.
sm =2:Uses alternate style for bar.
sRate=srsr is the scroll rate (vertical strips/second). If the chart recorder is in review mode negative numbers scroll in reverse.
title=titleStrSpecifies the chart title. Use "" for no title.
uMode=umUpdate mode.
um =1:Fast update with no bells and whistles.
um =2:Status line and positioning bar.
um =3:Status line, positioning bar, and animated pens.
win=winNameSpecifies which window or subwindow contains the named control. If not given, then the top-most graph or panel window or subwindow is assumed.
When identifying a subwindow with winName, see Subwindow Syntax for details on forming the window hierarchy.

Details

The target window must be a graph or panel.

The action of some of the Chart keywords depends on whether or not data acquisition is taking place. If the chart is in review mode then all keywords cause the chart to be redrawn. If data acquisition is taking place and the chart is in live mode, some keywords affect new data but do not attempt to update the part of the "paper" that has already been drawn. The following keywords affect only new data during live mode:

ppStrip, maxDots, gain, offset, color, lineMode

See Also

FIFOs and Charts

Controls and Control Panels for details about control panels and controls.

Control Panel Units for a discussion of the units used for controls.

The ControlInfo operation for information about the control.

The GetUserData function for retrieving named user data.

Demos

Open FIFO Chart Demo

Open Wave Review Chart Demo

Open Image Strip FIFO Demo